Latest Threat Research:Malicious dYdX Packages Published to npm and PyPI After Maintainer Compromise.Details
Socket
Book a DemoInstallSign in
Socket

dash-socket-api

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dash-socket-api

Wrapper for dash API

latest
npmnpm
Version
0.1.2
Version published
Maintainers
1
Created
Source

Dash Socket API wrapper

Allows interfacing to Open Dash via the Socket API

A single wrapper class that exposes setters and getters for various functions and values within dash.

Dash can be found here: https://github.com/openDsh/dash

Installation

npm install dash-socket-api

Usage

The test.js file can be used to test all available methods, comment out the not required commands, these are also show below

const Dash = require('dash-socket-api')
const dash = new Dash('192.168.0.6', 54545);

dash.on('connected', () => {
    //change dash page using string name
    dash.page("Camera");

    //change dash page using string key
    dash.cyclePage();

    //change dash page using array index
    dash.page(0);

    //get current page
    console.log(dash.page());

    //change mode
    dash.mode('Dark');

    //get current mode
    console.log(dash.mode());

    //change colour
    dash.color('#FF69B4');

    //get colour
    console.log(dash.color());

    //change brightness
    dash.brightness(150);

    //get brightness
    console.log(dash.brightness());

    //change volume
    dash.volume(100);

    //get volume
    console.log(dash.volume());

});

FAQs

Package last updated on 12 Mar 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts