Sensor Data Monitoring With Edison (Intel IoT)
Intro: Sensor Data Monitoring With Edison (Intel IoT)
This instructable is for integrating the grove sensors and actuators with Intel Edison by NodeJS and monitor the data of the sensors like air quality, Sound, Temperature, Light, Touch and LED, Buzzers.
This requires node modules:
mraa: GPIO,
moment-timezone: Date in specific timezone,
mathjs: logarithmic and mathematical calculations,
upm: LCD & i2c connectivity.
STEP 1: Sensors and Actuators Connection to Intel Edison
Connect the sensors and actuators as:
Temperature Sensor - Analog Pin 0,
Light Sensor - Analog Pin 1,
Sound Sensor - Analog Input 2,
Air Quality Sensor - Analog Pin 3,
Touch Sensor - Digital Pin 2,
Buzzer -Digital Pin 3,
LED -Digital Pin 4.
STEP 2: Programming Edison
Clone the repository -
git cone https://github.com/Shachindra/edisonProjectIoT.gi...
from https://github.com/Shachindra/edisonProjectIoT
check the file named as: SensorActuatorTest.js
install the modules (if not installed)
npm install mraa
npm install mathjs
npm install moment-timezone
after installation
node SensorActuatorTest.js
& see the code running in console.!
STEP 3: Extras
Use forever to run the program continuously;
npm install forever
forever start SensorActuatorTest.js
Check for Forever Process:
forever list
Getting GPS Data Serially:
Hook up your GPS Device as-
GPS TX - Edison RX
GPS RX - Edison TX
then install serialport module as
npm install serialport
node ReadSerialData.js
See the GPS data in Console.
I used a u-blox NEO-6 GPS Module (as seen in the picture).
More sensors can be connected and Data can be monitored.
Moreover the data can also be sent to the cloud for realization and graph plotting using iotkit agent, plotly, xively, etc. but that is going to be in my next instructable :-)
5 Comments
Reubenscott 8 years ago
Nice....
KBZ 8 years ago
Hi,
I would like to know what exactly is the ReadSerialData.js code doing? You are reading the data collected from sensors that is published on your serial interface(say Putty) and then you are reading that data - Am I getting this right?
If so, then where are you writing/displaying this data?
Shachindra92 8 years ago
KBZ 8 years ago
Thanks. I am not aware of any such library, but shall keep you posted if I come across one. I can read the data on the serial terminal of the edison, I want to transfer this from my Ubuntu machine to another server over ethernet. Any ideas how can I do this?
tomatoskins 8 years ago
I like this a lot! Thanks for sharing!