GithubHelp home page GithubHelp logo

js-station's Introduction

JS Station

This is a node.js based sensor station, it reads data from USB serial device and send them to SensorWeb. You can run it on Mac OS, Linux, and Windows.

Since our first initiative is to build a PM2.5 sensor network, we will demostrate below how to setup the station with PM sensor connected.

Hardware Requirements

  • Arduino Board
    • Currently we only develope and test it on Arduino Uno.
  • USB 2 TTL Adapter
    • Currently tested adapters are based on PL2303/FT232RL/CP2102 chipsets, make sure yours have 5V output.
  • Plantower PM Sensor with Cable

for Arduino and USB 2 TTL adapter, you only need one of them to get started.
Arduino will allow you to connect more different sensors in the future.

Setup Steps

Step 1: Install Arduino Firmware or USB to TTL Driver

If you use Arduino, simply upload the Plantower PMS3003 firmware with Arduino IDE.

If you use an USB to TTL Adapter but your computer can't detect it, try to install it's official driver. Below are driver download links for supported adapters:

Step 2: Connect Sensor

You only need to connect 4 pins of the PM Sensor, others should be left unconnected.

PM Sensor Pins USB Adapter Pins
VCC (PIN1) +5V
GND (PIN2) GND
RXD (PIN4) TXD
TXD (PIN5) RXD

Step 3: Setup and Run

Clone the repo: git clone https://github.com/sensor-web/js-station

Go to the js-station directory.

Do npm install to install dependencies.

Edit config.js to put your sensorId and apiKey in it, serialDeviceType: 'arduino' if you're using Arduino or set serialDeviceType: 'usbttl' if you're using supported USB to TTL Adpater.

Run node app.js then you'll see console output if success.

Maintainers

js-station's People

Contributors

evanxd avatar yshlin avatar elin-moco avatar

Watchers

James Cloos avatar John Hu avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.