• Quick Start
  • Booting
  • Platform
  • Portals
  • References
    • API Reference TOI3
    • IIP Reference
  • Resources
ARRIS Enterprises, Inc. Confidential Information

Example Portal Overview

The example portal, showing a video of the ARRIS racing team

Introduction

The KreaTV SDK includes an example portal designed to illustrate how the TOI API works. The example code implements a simple TV viewing application, with volume control, channel zapping, audio track and language selection and a few other features. It also can perform DVR, timeshift and scan for and connect to WiFi access points. It is designed to be easy to read and understand, and should help you get started with using the KreaTV platform API, TOI.

It is written in such a way that the HTML/CSS and UI related code is separated as much as possible from the TOI code, allowing you to focus on the KreaTV platform API.

File layout

The example portal is distributed as HTML and JavaScript files in the KreaTV SDK. After installing the SDK you should see the following directory structure in <sdk_root>/examples/example-html-portal

├── index.css
├── index.html
├── index.js
├── media.js
├── multiapp.js
├── powermanagement.js
└── modules
    ├── audio
    ├── keyboard
    ├── menu
    └── popup

Some *.css, *.tmpl and framework.* files are also present. These implement the example portal UI. It is not necessary to dig into these. The point of the example is to illustrate how to work with TOI, not how to write a portal, so the UI code has been hidden in these framework files when possible. UI related code is also removed from the code extracts presented in this documentation.

Disclaimer

This portal is written to be easy to read. It often performs tasks in a less than optimal way, for the sake of clear readability. Most of the TOI function calls can throw exceptions, which are rarely handled in this example code. Obviously in production-quality code you should always check for and handle exceptions! Please keep this in mind when developing your own applications/portals.

5.1.1.p8

Copyright (c) 2018 ARRIS Enterprises, LLC. All Rights Reserved. ARRIS Enterprises, LLC. Confidential Information.