Why migrate to Titan SDK?
The legacy DeviceInfo API was limited:- Brand-specific (Philips only)
- Restricted set of functionalities
- Unified Development: Write your code once and run it consistently across all supported Titan OS-powered TVs.
- New functionalities: Gain access to features like Accessibility (Text-to-Speech, Text Magnification) and App Control.
- Future-Proofing: The Titan SDK will continue to evolve with new capabilities and updates, while the DeviceInfo API will not be maintained from now and removed by the end of the year.
Step-by-Step Migration Guide
1
Remove Old DeviceInfo references
Remove any script references to the old DeviceInfo API from your
index.html
or build process to avoid accidental reliance on the deprecated object.2
Add the Titan SDK reference
3
Update Device and Capability Information
Replace all instances where you accessed properties directly from the global DeviceInfo object. Instead, use the New Way:
TitanSDK.deviceInfo.getDeviceInfo()
method.Old Way:4
Test Your Migrated Application
Thoroughly test your application on various TVs powered or maintained by Titan OS to ensure all functionalities work as expected post-migration. Pay close attention to:
- All device information calls returning correct data.
- Features that relied on old DeviceInfo properties.
- New SDK features you’ve integrated.
5
Start integrating and exploring new features, such as Accessibility, App Control
With the Titan SDK integrated, begin exploring and implementing its new functionalities:
- Accessibility: Utilize
TitanSDK.accessibility.isTTSSupported()
,TitanSDK.accessibility.startSpeaking()
,TitanSDK.accessibility.onTTSSettingsChange()
and other methods as detailed in the Accessibility Guide for TitanSDK Apps. - App Control: Leverage
TitanSDK.apps.launch()
for streamlined app-to-app interactions. - Remote Control: Refer to the Remote Control & Key Handling section for unified key mapping.
Migration Map: DeviceInfo API → Titan SDK
Here is a mapping of common DeviceInfo API properties and their Titan SDK equivalents:Old DeviceInfo Property | New Titan SDK Equivalent (Function & Key) | Notes & Example |
---|---|---|
DeviceInfo.Channel.vendor | await TitanSDK.deviceInfo.getDeviceInfo().Channel.vendor | Retrieves the vendor name of the device. |
DeviceInfo.Channel.brand | await TitanSDK.deviceInfo.getDeviceInfo().Channel.brand | Retrieves the brand name of the device. |
DeviceInfo.Product.platform | await TitanSDK.deviceInfo.getDeviceInfo().Product.platform | Accesses the device’s platform name. |
DeviceInfo.Product.year | await TitanSDK.deviceInfo.getDeviceInfo().Product.year | Retrieves the model year of the device. Example: const info = await TitanSDK.deviceInfo.getDeviceInfo(); console.log(info.Product.year); |
DeviceInfo.Product.deviceID | await TitanSDK.deviceInfo.getDeviceInfo().Product.deviceID | Retrieves the unique device identifier. |
DeviceInfo.Product.firmwareVersion | await TitanSDK.deviceInfo.getDeviceInfo().Product.firmwareVersion | Accesses the firmware version of the device. |
DeviceInfo.Product.WhaleAdID | await TitanSDK.deviceInfo.getDeviceInfo().Product.WhaleAdID | Retrieves the advertising ID. |
DeviceInfo.Product.firmwareComponentID | await TitanSDK.deviceInfo.getDeviceInfo().Product.firmwareComponentID | Accesses the firmware component identifier. |
DeviceInfo.Capability.os | await TitanSDK.deviceInfo.getDeviceInfo().Capability.os | Retrieves the operating system name. |
DeviceInfo.Capability.browserEngine | await TitanSDK.deviceInfo.getDeviceInfo().Capability.browserEngine | Accesses the browser engine used by the device. |
DeviceInfo.Capability.hasStorage | await TitanSDK.deviceInfo.getDeviceInfo().Capability.hasStorage | Checks if the device has persistent storage. |
DeviceInfo.Capability.support3d | await TitanSDK.deviceInfo.getDeviceInfo().Capability.support3d | Checks for 3D content support. |
DeviceInfo.Capability.supportUHD | await TitanSDK.deviceInfo.getDeviceInfo().Capability.supportUHD | Checks for Ultra High Definition (UHD) display support. |
DeviceInfo.Capability.supportHDR | await TitanSDK.deviceInfo.getDeviceInfo().Capability.supportHDR | Checks for High Dynamic Range (HDR) display support. (Note: New TitanSDK also provides supportHDR_HDR10 and supportHDR_DV for more specific checks.) |
DeviceInfo.Capability.supportWebSocket | await TitanSDK.deviceInfo.getDeviceInfo().Capability.supportWebSocket | Checks for WebSocket protocol support. |
DeviceInfo.Capability.supportPlayready | await TitanSDK.deviceInfo.getDeviceInfo().Capability.supportPlayready | Checks for Microsoft PlayReady DRM support. |
DeviceInfo.Capability.supportWidevineModular | await TitanSDK.deviceInfo.getDeviceInfo().Capability.supportWidevineModular | Checks for Google Widevine Modular DRM support. |
DeviceInfo.Capability.supportWidevineClassic | await TitanSDK.deviceInfo.getDeviceInfo().Capability.supportWidevineClassic | Checks for Google Widevine Classic DRM support. |
DeviceInfo.Capability.supportClearKey | - | This property does not appear in the new TitanSDK’s capability response. Please verify if still needed or if there’s an alternative. |
DeviceInfo.Capability.supportPrimetime | - | This property does not appear in the new TitanSDK’s capability response. Please verify if still needed or if there’s an alternative. |
DeviceInfo.Capability.supportFairplay | - | This property does not appear in the new TitanSDK’s capability response. Please verify if still needed or if there’s an alternative. |
DeviceInfo.Capability.supportAdobeHDS | await TitanSDK.deviceInfo.getDeviceInfo().Capability.supportAdobeHDS | Checks for Adobe HTTP Dynamic Streaming support. |
DeviceInfo.Capability.supportAppleHLS | await TitanSDK.deviceInfo.getDeviceInfo().Capability.supportAppleHLS | Checks for Apple HTTP Live Streaming support. |
DeviceInfo.Capability.supportMSSmoothStreaming | await TitanSDK.deviceInfo.getDeviceInfo().Capability.supportMSSmoothStreaming | Checks for Microsoft Smooth Streaming support. |
DeviceInfo.Capability.supportMSSInitiator | await TitanSDK.deviceInfo.getDeviceInfo().Capability.supportMSSInitiator | Checks for Microsoft Smooth Streaming Initiator support. |
DeviceInfo.Capability.supportMPEG_DASH | await TitanSDK.deviceInfo.getDeviceInfo().Capability.supportMPEG_DASH | Checks for MPEG-DASH streaming support. |
DeviceInfo.Capability.drmMethod | await TitanSDK.deviceInfo.getDeviceInfo().Capability.drmMethod | Retrieves the primary DRM method used by the device. |
DeviceInfo.Capability.supportOIPF | await TitanSDK.deviceInfo.getDeviceInfo().Capability.supportOIPF | Checks for Open IPTV Forum (OIPF) support. |
DeviceInfo.Capability.supportEME | await TitanSDK.deviceInfo.getDeviceInfo().Capability.supportEME | Checks for Encrypted Media Extensions (EME) support. |