Samsung smart view

Функции Samsung Smart View

Программа поставляется разработчиком для смартфонов, планшетов и персональных компьютеров, работающих на платформе Android, iOS, Windows и Windows Phone. Основная задача утилиты — это полное взаимодействие Смарт-телевизора Самсунг с другими электронными устройствами.

Приложение Smart View включает следующие функции:

  1. использование внешнего устройства в качестве пульта. Управлять телевизором можно с помощью телефона или компьютерной мыши;
  2. просмотр содержимого любого внешнего накопителя, а также воспроизведение любых мультимедийных файлов (видеоклипы, аудиоролики, изображения и анимации);
  3. просмотр фильмов, новостей, спортивных состязаний цифрового ТВ на смартфоне или ПК;
  4. программное включение и отключение телевизора с помощью вспомогательного устройства;
  5. управление виджетами и прочими утилитами сервиса Smart Hub;
  6. настройка и управление спящим режимом.

Все эти возможности открываются я благодаря нескольким утилитам, которые можно использовать в приложении Samsung Smart View:

  • TV Remote. Данная опция позволяет управлять телевизором Samsung с помощью мобильного телефона или ПК. При входе в утилиту на экране устройства появляется электронная раскладка, дублирующая кнопки на пульте. Выбор нужного нажатия выполняется с помощью сенсора на планшете или компьютерной мыши.
  • Dual View. С помощью этой утилиты пользователь может полностью синхронизировать трансляцию изображения. На практике доступен просмотр телеканалов со смартфона или ноутбука, или наоборот, открывается доступ к контенту внешнего устройства в телевизоре. Синхронизация выполняется по беспроводной связи Bluetooth, следовательно, не исключены задержки до нескольких секунд.
  • Bluetooth PowerON. Опция позволяет управлять спящим режимом и системным включением телевизора. Для ее использования в Смарт ТВ должен быть встроенный или подключенный через USB-вход Bluetooth-роутер.
  • Game Remote. Утилита для игрового режима, с которой смартфон превращается в джойстик. Включает ограниченный и полный режимы, последний из которых поддерживает гироскопическое управление. Опция не предусмотрена в приложении
  • Smart. Пользователь получает полный доступ к сервису Smart Hub. Доступна синхронизация телевизора с удаленным сервером.

Возможные неполадки

Иногда может произойти ситуация, при которой приложение Samsung Smart View отказывается работать.

Ниже предлагается перечень частых проблем и их решение:

  • Не находит телевизор. Требуется обновление программного обеспечения. Данная проблема актуальна для телевизоров и др. поддерживаемых устройств 2011-14 г.в., которые еще не относятся к Smart-устройствам, но уже поддерживают сервис Smart Hub. Пакет обновлений можно получить с помощью синхронизации с сервисом TENET.
  • Соединение не устанавливается или большая задержка в передаче данных. Нужно сократить расстояние между телевизором и смартфоном/ПК. Для беспроводной передачи характерна потеря части данных на большой удаленности.
  • Не выполняется воспроизведение содержимого с компьютера или планшета. Нужно отключить антивирус на подключенном устройстве, т.к. он блокирует доступ к нему.
  • Телевизор не отвечает на команды. Нужно проверить работоспособность встроенного Bluetooth-модуля или правильность подключения внешнего роутера.
  • Приложение «вылетает». В этом случае телефон не рассчитан на работу со Samsung Smart View, нужно обновить Андроид.

Latest SmartViewSDK include Enhaned WOW feature

SDK 2.4.0 makes your app enable WOW function automatically without NO source code change.

  1. If your app have been connected once,

    • SDK manage the TV device list for WOW feature
    • SDK handles below Basic UI scenario
  2. Basic UI scenario

    • Turn the TV off (put to standby).
    • Appears marked as “TV_NAME(standby)” within 7 seconds.
    • Select the TV.
    • The TV power on
    • The TV WebApp(or DMP) should start loading on the TV.
    • The video should start playing on the TV.

New Feature will do the following:

  1. Show standby devices: Devices which were successfully connected in the past but now are switched-OFF will be visible to the Application developer after 7 seconds when he/she starts discovery
  1. Integrated Connect API: Calling connect on the standby devices will try to wake the TV if switched off. Then it will try for 1 minute to get updated service from the switched-ON TV. If able to get the service then will connect with the TV.

In order to use this feature the following new APIs are available for Developer’s ease:

  1. WOW on/off:
    — Search.start() : By default will show standby devices.
    — Search.start(false) : will disable this feature and the Application developer will no longer be shown standby devices
  2. Service.remove()
    will remove the stored standby service from the Data base
  3. Search.clearStandbyDevices()
    will clear all the saved devices from the Data base

Apart from the new APIs, there are also Error codes added for different scenarios to help the developer identify the problem

  1. ERROR_HOST_UNREACHABLE: This error can be received in the completion handler of connect function. It will be received, there can be various reasons:
  1. TV power OF
  2. TV Switched ON but discovery not done in 1 minute
  1. ERROR_ALREADY_CONNECTED: This error comes when User tries to connect to already connected device. Error can be received in the completion handler of connect function.
  2. ERROR_CONNECT_FAILED: When connection failed due to reasons other than Host unreachable. This error will be received in OnConnect() of Channel Delegate protocol
  3. ERROR_WEBSOCKET_DISCONNECTED: After connection to TV is successful but due to some reason, the websocket disconnects. This error will be received in OnError() of Channel Delegate protocol

Implement manually lower version of SDK 2.4.0

1. Simple implementation guide

The Mobile device must get TV’s MAC info when connected successfully.

The Mobile device must store certain values(MAC), so that the Mobile device can use Wake-up to power on the TV next time.

2. Pre-condition

(MUST) Mobile App should have connected successfully at least once so that TV can register mobile MAC.

When TV is turned off, the TV status should be displayed as “{TV Name} (standby)” on the mobile device.

3. Basic UI scenario

  1. Turn the TV off (put to standby).
  2. Within 60 seconds TV disappears from the list and within 30 seconds reappears marked as «(standby)».
  3. Select the TV.
  4. The TV should start loading.
  5. The TV WebApp(or DMP) should start loading on the TV.
  6. The video should start playing on the TV.

4. API Usage

1) How to get MAC address:

2) Wake up TV :

3) Wake up TV and connect :

This API turns on the selected TV and Smart View SDK confirm to be ready.

Then, you can turn on the TV and launch your application.

BLE Discovery (Bluetooth Low Energy)

Smart View framework supports discovery of Samsung devices via Bluetooth Low Energy in the surrounding area.

BLE discovery allows user to see the list of available TVs that user can connect with. BLE discovery does not support retrieving the Service objects using Bluetooth currently.

The following example demonstrates how to launch BLE discovery and get the discovered devices.

Stop BLE Discovery:

Support Multitasking

The default value for multitasking support is true. Your application should support multitasking

Your app will change the background state in the following circumstances

  • Launching other application over currently running application.
  • Calling method.
  • Turning off TV during application running in Samsung Instant On mode.
  • Clicking «Smart Hub» button and going to the Apps page.

Your App can select one of two operation.

  • Keep connection
  • Close connection

Keep connection

Webapp and mobile app keep the connection.

and mobile app can change the state TV app(background to foreground)

Example Javascript API Usage(Web App)

Example mobile API Usage

TLS (make secure connection)

SmartviewSDK can make secure connection between sender and receiver through wss & http

refer to latest CastVideo sample app.

1) setSecurityMode API

setSecurityMode(security:completionHandler:)

  • Set security mode status to for web socket connection or rest API
  • Parameters:
    • securityMode — security mode status to set
    • result — result to return whether security mode was set or not

2) Sample Code

Подписаться
Уведомить о
guest
0 комментариев
Межтекстовые Отзывы
Посмотреть все комментарии