MQ303A Class
- ID: mq303a
- Name: Alcohol Detection Sensor
- Other Names: Grove Alcohol Sensor
- Category: gaseous
- Manufacturer: seeed
- Link: http://www.seeedstudio.com/wiki/Grove_-_Alcohol_Sensor
- Connection: analog gpio
- Kit: tsk
UPM module for the MQ303A alcohol sensor. This sensor needs to be warmed up before stable results are obtained. The higher the value returned from value() , the higher the amount of alcohol detected.
Item Index
Methods
Methods
MQ303A
(
Number
-
pin
-
heaterPin
MQ303A constructor
Parameters:
-
pin
NumberAnalog pin to use
-
heaterPin
NumberDigital pin mapped to the analog pin to use
Returns:
Number:
value
()
Number
Gets the alcohol reading from the sensor. The value read from the analog pin is inverted. A higher returned value means a higher amount of alcohol detected.
Returns:
Number:
Alcohol reading
heaterEnable
(
-
enable
Enables the heater
Parameters:
-
enable
BooleanEnables the heater if true; otherwise, disables it