sensordrone

Node.js lib for the Sensordrone

node-sensordrone

Node.js lib for the Sensorcon Sensordrone

Special thanks to @mrose17 for sending me a Sensordrone!

Notes

npm install sensordrone
var Sensordrone = require('sensordrone');
Sensordrone.discover(callback(sensordrone));
sensordrone.connect(callback);
sensordrone.disconnect(callback);
sensordrone.discoverServicesAndCharacteristics(callback);
sensorTag.readBatteryVoltage(callback(voltage));
// values 0 - 255 
sensordrone.setLeds(leftRed, leftGreen, leftBlue, rightRed, rightGreen, rightBlue, callback);
sensorTag.readAmbientTemperature(callback(temperature));
sensorTag.readHumidity(callback(humidity));

Enable/disable:

sensordrone.enablePressure(callback);
 
sensordrone.disablePressure(callback);

Read:

sensordrone.readPressure(callback(pressure));

Enable/disable:

sensordrone.enableAltitude(callback);
 
sensordrone.disableAltitude(callback);

Read:

sensordrone.readAltitude(callback(altitude));

Enable/disable:

sensordrone.enableRGBC(callback);
 
sensordrone.disableRGBC(callback);

Read:

sensordrone.readRGBC(callback(r, g, b, c, lux, temp)); // temp in Kelvins 

Enable/disable:

sensordrone.enableIrTemperature(callback);
 
sensordrone.disableIrTemperature(callback);

Read:

sensordrone.readIrTemperature(callback(temperature));
sensordrone.readPrecisionGas(callback(ppmCO));

Enable/disable:

sensordrone.enableOxidizingGas(callback);
 
sensordrone.disableOxidizingGas(callback);

Read:

sensordrone.readOxidizingGas(callback(ohms));

Enable/disable:

sensordrone.enableReducingGas(callback);
 
sensordrone.disableReducingGas(callback);

Read:

sensordrone.readReducingGas(callback(ohms));
sensordrone.readADC(callback(voltage));

Enable/disable:

sensordrone.enableCapacitance(callback);
 
sensordrone.disableCapacitance(callback);

Read:

sensordrone.readCapacitance(callback(capacitance));

Write:

sensordrone.writeUart(data, callback);

Read:

sensordrone.readUart(callback(data));

External CO2 sensor

Setup:

sensordrone.setupExternalCO2(callback);

Read:

sensordrone.readExternalCO2(callback(ppm));