Sensors Simple API
Sensors#
What do you want to measure?
Simple API#
| API | Description | Details |
|---|---|---|
getStatus() | Gets the status of any generic GPIO pin | Read More |
getAdc() | Get the Adc value from the sensor | Read More |
getLux() | Get the Lux value from the sensor | Read More |
getCm() | Gets the distance from supported sensors | Read More |
getBpm() | Gets the Heart rate from supported sensors | Read More |
getLph() | Gets the Flow from supported sensors | Read More |
motionStatus() | Get the status of the motion sensor | Read More |
proxmityStatus() | Get status from the proximity sensor | Read More |
touchStatus() | Get status from the touch sensor | Read More |
lightStatus() | Get status from the light blocking sensor | Read More |
tiltStatus() | Get status from the light blocking sensor | Read More |
Detailed Description#
getAdc()#
Description : Gets the status of any generic GPIO pin
Parameters
channelADC Channel number
Return-type : int16_t
Returns : int16_t digital value for analog reading on Success and -1 on Failure
Usage :
Supported ADC's#
getBpm()#
Description : Gets the Heart rate from supported sensors.
Return-type : int16_t
Returns : int16_t The Heart rate in bpm.
Usage :
getCm()#
Description : Gets the distance from supported sensors.
Return-type : int16_t
Returns : int16_t The distance in cm.
Usage :
getLph()#
Description : Gets the Flow from supported sensors.
Return-type : int16_t
Returns : int16_t The Flow in Liters per hour.
Usage :
getLux()#
Description : Get the Lux value from the sensor.
Return-type : int16_t
Returns : int16_t the lux value on Success and -1 on Failure.
Usage :
getStatus()#
Description : Gets the status of any generic GPIO pin.
Parameters
phyPinThe phy pin
Return-type : int8_t
Returns : int8_t GPIO pin values on Success and -1 on Failure
Usage :
lightStatus()#
Description : Get status from the light blocking sensor.
Return-type : int8_t
Returns : 1 if light detected else 0, -1 if error
Usage :
motionStatus()#
Description : Get the status of the motion sensor.
Return-type : int8_t
Returns : 1 if motion detected else 0, -1 if error
Usage :
proxmityStatus()#
Description : Get status from the proximity sensor.
Return-type : int8_t
Returns : 1 if proximity detected else 0, -1 if error
Usage :
tiltStatus()#
Description : Get status from the tilt sensor.
Return-type : int8_t
Returns : 1 if tilt detected else 0, -1 if error
Usage :
touchStatus()#
Description : Get status from the touch sensor.
Return-type : int8_t
Returns : 1 if touch detected else 0, -1 if error
Usage :