Apple TV debugging - 24i/fokuson-developer-portal GitHub Wiki
This is a guide that will explain how to start a TVOS simulator, install a fokusOn TVOS debug app, use Safari dev tools to debug, and change the portal URL used by the debug app.
- Mac with the latest Os and Xcode installed
- Access to at ATV debug build on the FTP
To find the simulator id run this command
#!console
xcrun simctl list
and look for this section and copy the DEVICE-ID of the simulator you want to use (eg. E38D3F29-289D-4283-B39D-967AD56BBE7C)
#!console
-- Unavailable: com.apple.CoreSimulator.SimRuntime.tvOS-13-3 --
Apple TV (E38D3F29-289D-4283-B39D-967AD56BBE7C) (Shutdown) (unavailable, runtime profile not found)
Apple TV 4K (EB478412-2797-451A-8D00-9578531C2FCC) (Shutdown) (unavailable, runtime profile not found)
Apple TV 4K (at 1080p) (B606D10A-6B58-4895-9D65-8D33E62165A7) (Shutdown) (unavailable, runtime profile not found)
To start the simulator run this command
#!console
/Applications/Xcode.app/Contents/Developer/Applications/Simulator.app/Contents/MacOS/Simulator -CurrentDeviceUDID <DEVICE-ID>
Example:
#!console
/Applications/Xcode.app/Contents/Developer/Applications/Simulator.app/Contents/MacOS/Simulator -CurrentDeviceUDID E38D3F29-289D-4283-B39D-967AD56BBE7C
Unzip the debug app that you downloaded from the FTP.
To install the debug app run this command.
#!console
xcrun simctl install <DEVICE-ID> <PATH-TO-DEBUG-APP>
Example:
#!console
xcrun simctl install E38D3F29-289D-4283-B39D-967AD56BBE7C ./fokusOn.app
Now you can launch the app.
NB!! If you get an error like install apps from unidentified developers, not allowed. Check out this link https://www.cnet.com/how-to/3-ways-to-install-apps-from-unidentified-developers-on-macos-sierra/
Start the simulator and open safari.
Go to the menu "Develop" and find the simulation (Simulator -- Apple TV -- tvOS 13.4)
Then select "com.nordija.multiscreen"
Now you can start debugging the app.
NB!! if you can find the "Develop" menu check out how to enable it here. https://support.apple.com/guide/safari/use-the-developer-tools-in-the-develop-menu-sfri20948/mac
Open the dev tools in safari see (How to use the safari dev tools to debug the app)
Then go to the console and execute the command
#!javascript
nativeBridge.openDebugMenu()
Then the app will open a window where you can change the portal URL.