Skip to content

This is a demo application for a light control system using 6lowpan.(Temporary - will be removed tomorrow)

License

Notifications You must be signed in to change notification settings

ARMmbed/light-control-web-app-Temporary-OuluWorkshop

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Light Control

Control connected outlets using a web interface

Installation and Running

Installing Dependencies

To install all dependencies:

npm install

Configuration

Light Control uses dotenv for configuration. The following configuration properties should be set in a .env file in the same directory as app.js:

  • URL - URL to the dashboard (including port if necessary, eg. mylightcontrol.com or mylightcontrol.com:4000)
  • PORT - Port to use for the dashboard (4000 is used by default if this is not specified).
  • MDS_HOST - URL to the mbed Device Server (mDS) instance/mbed Connector
  • MDS_DOMAIN - Domain being used in mbed Device Server (mDS) instance
  • MDS_TOKEN - Token to use for mbed Connector authentication (not needed if using mDS basic auth)
  • MDS_USERNAME - mDS basic auth username (not needed if using token authentication)
  • MDS_PASSWORD - mDS basic auth password (not needed if using token authentication)
  • ENDPOINT_TYPE - Endpoint type of the connected outlets
  • ENDPOINT_RESOURCE - Path to the endpoint's resource linked to the relay state
  • ENDPOINT_NAME_RESOURCE - Path to the endpoint's resource that gives its name

Running the App

Start the server using the following command:

node app.js

Or leave it running continuously:

nohup node app.js &

About

This is a demo application for a light control system using 6lowpan.(Temporary - will be removed tomorrow)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages