If you are building a digital signage or kiosk solution, you need to make a decision on which devices will you support. With an ever-growing number of devices on the market, it's time-consuming and resource-heavy to keep up and maintain your application. You need to solve many hardware-related issues and optimizations.
The signageOS Applet is solving this issue. The Applet is your HTML5 application which is leveraging unified signageOS JS SDK. The Applet can be easily deployed onto any supported device and remotely managed.
What is Applet (aka universal HTML5 Player)
signageOS ("sOS") provides a unification SDK for running the same Applet on any of the supported devices. With Applet, you maintain a single codebase for your content playout.
Key features of Applet
Here are some of the great features making your Applet development as effective as possible.
JS SDK
Within Applet we prepared a special Javascript SDK. This JS SDK helps you with basic tasks that are not supported natively by the browser - local file management, accelerated video playback, video inputs playback, and other hardware-specific features and device management features.
JS SDK is designed in a way it will not interfere with any of your code. JS SDK consists of building blocks and functions allowing you to design your logic in the way you want. It's not telling you anything about how to play content or how to schedule your videos.
JS SDK Examples
// Saving files into device memory before an initial load
await sos.offline.addFilesSync([
{
uri: "https://ajax.googleapis.com/ajax/libs/jquery/2.2.4/jquery.min.js",
uid: "jquery-2.2.4.min.js",
type: sos.offline.types.javascript,
flags: [sos.offline.flags.append(document.body)],
},
]);
// Save video to device storage (https://docs.signageos.io/api/sos-applet-api/#Load_or_Save_specific_file_into_internal_memory)
const { filePath } = await sos.offline.cache.loadOrSaveFile('intro-video', 'https://2.signageos.io/assets/video-test-1_e07fc21a7a72e3d33478243bd75d7743.mp4');
// Play videos with accelerated video players (https://docs.signageos.io/api/sos-applet-api/#Play_video)
await sos.video.play(...videoArguments);
await sos.video.stop(...videoArguments);
Versioning
Applets feature a built-in versioning system allowing you to create an unlimited number of versions and assign it to devices of your choice.
Distribution
signageOS provides you with a safe and secured distribution mechanism. Selected Applet versions can be assigned to selected devices via REST API or Box.
On top of that, there are Applet management features in Power Action, allowing you remotely refresh, reload, enable or disable your Applet.
Debugging
With Applets, you get additional debugging options. You can start a remote session via Weinre or connect to the device in the local network from CLI.
Configuration (ENVs)
signageOS allows you to set up a unique Applet configuration for each device. With this mechanism, you can easily assign custom parameters or environmental variable for your Applet.
How to develop your Applet
There are two main methods to develop an Applet that is compatible with the signageOS Core App:
- signageOS CLI (full-features desktop development), recommended option
- signageOS Web Editor (quick and easy for lightweight applications)
For both cases, Applet is developed as an HTML5/Javascript application. It allows you to use any common developer approach and utilize your stack.
signageOS CLI
To start working with signageOS CLI is straightforward. Install signageOS CLI onto your PC or Mac and start the development:
npm install @signageos/cli -g
sos --help
Start Your development with CLI
Continue hereUse your existing application with CLI
Continue heresignageOS Web Editor (legacy)
Web Editor is available within signageOS Box. You can quickly create a new Applet and build a single-file application. The Web Editor approach is recommended for quick API testing or for the development of lightweight applications like iframe/browser launchers.
Let's check the complete guide on the Web Editor.