I had to buy an USB-C to USB-A cable to connect the Apple TV to my Mac book, because Apple informed me that using iTunes on a Mac is the only way to update the Apple TV. That cable did not come with my developers kit so it took some time to get one, as an USB-C cable is not yet in my otherwise large cable collection.
Hello TV!
So I connected the two devices only to find out that iTunes was not able to connect to the server. So, no update yet. But it was fun to find out that I was able to deploy directly from xCode to the TV.
It is not really different from running an app on your iPhone but I was surprised because I thought I had to use the TestFlight app for that and so far I had seen my early creations on the simulator only.
Get up to speed
There is no need to dive into TVML right away. You can use existing Objective-C or Swift code or code snippets and get up to speed with tvOS real quickly. The downside is that currently not all frameworks that exists for iOS are available for tvOS (yet). For some of them that makes sense as Apple TV development comes with some known limitations.
One of them is the lack of any option for local persistency. All application data needs to be stored in the (i)cloud. What makes less sense is that, for example, the Event Kit framework is missing for tvOS. I am sure there will be a workaround for this but these kind of things do not make the life of a tvOS developer very easy.
Parse & tvOS
Using SDKs from third parties in your tvOS project can be an issue as well. For my app I want to store data in the cloud using Parse. I cannot use iCloud because I want to share the app with Apple TV and with Android TV users.
Unfortunately Parse cannot be used, basically because the SDK supports caching and other local persistancy features. It is not going to work and you have to wait until the guys at Parse release a tvOS specific version of their SDK or you can try to use the Parse Rest API and do some things yourself.
Conclusion
Since I am a huge fan of Parse I really miss their SDK for tvOS. On GitHub you can find a Parse REST API approach for tvOS. It is written in Swift and although minimalistic it looks like an interesting start to make my tv app work with Parse anyway.
I still have not totally grokked tvOS yet and how to work around existing limitations but I am doing some great research on the topic. In the mean time you can check out some interesting resources on the topic. There are some nice examples available here. Or check this site or this one.
Or watch this video or this one.
No comments:
Post a Comment