Tutorials

Running a HbbTV application on a hybrid terminal

Introduction

HbbTV application development and testing can be performed using different emulators, e.g. RedOrbit HbbTV Emulator or HybridTV Dev Environment (please note that other emulator alternatives exist). However, no emulator environment emulates 100% functionality of a hybrid terminal. Therefore it is quintessential to validate any HbbTV application on a hybrid terminal before rolling it out to the end users.

System overview

A hybrid terminal (e.g. a smart TV set) can be connected to two networks in parallel. On the one side it can be connected to a broadcast DVB network (e.g. DVB-T, DVB-S or DVB-C). Via this broadcast connection the hybrid terminal can receive standard broadcast A/V (i.e. linear A/V content).

In addition the hybrid terminal can be connected to the Internet via a broadband interface. This allows bi-directional communication with the application provider. Over this interface the terminal can receive application data and non-linear A/V content (e.g. A/V content streaming on demand).

Figure below depicts the system overview with a hybrid terminal connected to both of these networks in parallel:

In this scenario the broadcast signal also holds the AIT (Application Information Table) data. The Application Manager of the Hybrid terminal evaluates this AIT data. AIT data holds the URL (Uniform Resource Locator) of the HbbTV application. The Browser of the Hybrid terminal is responsible for downloading, presenting and executing the HbbTV application singalled within the AIT data of the Broadcast signal.

Checklist

In order to run a HbbTV application on a smart TV set the following is needed:

  • A broadcast a/v stream that also includes custom AIT data (AIT data holds the URL of the HbbTV application that one wishes to run)
  • A DVB modulator that can modulate the broadcast a/v stream so it can be demodulated and decoded by the hybrid terminal (e.g. DVB-T modulator)
  • A web server hosting the HbbTV application that one wishes to run
  • A hybrid terminal (a smart TV set or a Set Top Box that supports HbbTV)
    • The hybrid terminal must be connected to a network that enables bi-directional communication with the Web server which hosts the HbbTV application (HTTP/HTTPS communications protocol is used)

Generating the broadcast a/v stream

There are several online tutorials that explain how to generate the Broadcast stream with AIT data included, for example: https://github.com/cta-wave/dpctf-deploy/issues/1#issuecomment-771048901.

The European Broadcasting Union hosts the hbbtv-dvbstream project on GitHub that leverages other open source software in order to facilitate launch of HbbTV applications on hybrid terminals:  https://github.com/ebu/hbbtv-dvbstream. This project can be used to generate the Broadcast stream in TS (Transport Stream) file format.

DVB modulator

Possible examples of a DVB modulator device include:

DISCLAIMER:

Other modulator alternatives may exist. Listed are examples provided by HbbTV members. HbbTV itself is not recommending or endorsing usage of any particular modulator products.

Web server hosting the HbbTV application 

IMPORTANT NOTE:

For HbbTV applications authored for versions 1.1.1 and 1.2.1 of the ETSI TS 102 796 standard all XHTML documents of an application should be served with the MIME content type “application/vnd.hbbtv.xhtml+xml”, since terminals supporting these versions of the standard are not required to load or run documents which are served with a MIME type other than “application/vnd.hbbtv.xhtml+xml”. Terminals supporting later versions of the standard support the MIME types defined for HTML5 but should also support the “application/vnd.hbbtv.xhtml+xml” MIME type in order to run applications authored for previous versions of the standard.

The HbbTV application must be hosted on a web server, for example Apache (https://httpd.apache.org/) or nginx (https://www.nginx.com/). The application URL must be accessible by the  hybrid terminal device. If the hybrid terminal can access the public internet then this could be hosted anywhere in the cloud. If the hybrid terminal is limited to only accessing the network in your office then you will need to host it locally somehow.

Hybrid terminal

Any smart TV set or a STB (Set Top Box) that supports HbbTV can be used as a receiver device which can run HbbTV applications.

A practical example

This step-by-step tutorial explains how to launch the Hello world application presented in the Guidelines section of the portal.

Step 1: On the web server which will be used to serve the application clone the application source code using command:

Validate installation by running the application from the web server by using one of the emulators, e.g. RedOrbit HbbTV Emulator or HybridTV Dev Environment. The Hello world application is contained within the hello-world directory.

Step 2: Install hbbtv-dvbstream from https://github.com/ebu/hbbtv-dvbstream following the tutorial available within the project’s README file.

Step 3: Edit the create-metadata-ts.py script so the created AIT table holds the Hello world application URL. This is done via the appli_root and appli_path variables within the create-metadata-ts.py script. Once the variables are set run the make-stream.sh script to generate the TS (Transport Stream) file with the broadcast stream.

Step 4: Use the TV modulator and accompanying software to playout the generated TS file and modulate it to a modulation supported by the hybrid terminal (e.g. DVB-T).

Step 5: Perform channel scan on the hybrid terminal (channels EBU-CPA1 and EBU-CPA2 as defined in create-metadata-ts.py script should be found by the Hybrid terminal). Make sure that the Hybrid terminal is connected to the network so it can reach the Hello world application installed on the web server.

Step 6: Tune to the channel which holds the AIT signalling for the application and the Hello world application should start automatically.