npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@dgtgroup/centoplayer-sdk

v1.2.9

Published

The CentoPlayer SDK provides useful functions to interact with CentoPlayer on Linux and WebOS (limited).

Readme

Centoplayer App SDK

Development

  • run with: npm start
  • browse to /test subdirectory on: http://127.0.0.1:8080

Getting started

npm i @dgtgroup/centoplayer-sdk
import { CentoSDK } from '@dgtgroup/centoplayer-sdk';

// Wait for initialization & Cento-player info:
CentoSDK.on('initialized', (playerInfo: Cento.Info) => {
  console.log('🟢 CENTO-SDK IS INITIALIZED');
  console.log('🟢', playerInfo);
});

Angular implementation

As the SDK emits events that are outside of Angular's Zone, they do not get picked up by Angular's change Detection. In case a rerender is required, use ngZone.run() to trigger change detection:

CentoSDK.on('methodname', () => {
  this.ngZone.run(() => {
    this.myCustomFunction(value);
  });
});

Available methods

Implemented

centoSDK.getPlatform() Returns the current platform information: webos, centoplayer (=linux), DEVMODE

centoSDK.getSerialNumber() Returns the serial number of the device.

centoSDK.getPlayerInfo() Returns information about the media player as a Cento.Info object.

centoSDK.playlistStop(preload?:boolean) centoSDK.playlistStart() Starts or stops the current playlist. Preload option will prepare the next item in the playlist for instant playback.

Note: WebOS supports playback of only one video at a time. Starting a new video will automatically stop any currently playing video across the entire Signage Player. Ensure you stop any playing video before starting a new one in your application.

Awaiting implementation

centoSDK.reboot() centoSDK.refresh() centoSDK.displayOn() centoSDK.displayOff() centoSDK.showConsole() centoSDK.hideConsole() centoSDK.getVolume() centoSDK.setVolume(value: number) centoSDK.openPlayerUI() centoSDK.showKeyboard() centoSDK.hideKeyboard()

Events

centoSDK.on('initialized', (playerinfo: Cento.Info)=>{ ... }) centoSDK.on('serial', (value:string)=>{ ... }) centoSDK.on('keydown', (e:KeyboardEvent)=>{ ... }) centoSDK.on('keyup', (e:KeyboardEvent)=>{ ... })

Serial Communication

Listening to Serial Input events (eg. qrcode scanner):

onSerial(value: string) {
  console.log('Scanned value:', value);
}
const bind = this.onSerial.bind(this);

CentoSDK.on('serial', bind);
CentoSDK.off('serial', bind);

Keyboard events

centoSDK.on('keydown', (evt: KeyboardEvent) => {
  console.log('Key-down event:', evt);
});
centoSDK.on('keyup', (evt: KeyboardEvent) => {
  console.log('Key-up event:', evt);
});