The reference to 37 sensors and modules has been widely circulated on the Internet. In fact, there must be more than 37 sensor modules compatible with Arduino. In view of the fact that I have accumulated some sensors and modules on hand, according to the concept of true knowledge (must be done by hands), for the purpose of learning and communication, I am going to try and do experiments one by one here, and will record them whether they are successful or not—Xiao Xiao The progress or problems that cannot be solved, I hope to be able to throw bricks and spark jade.
[Arduino] 108 sensor module series experiments (data + code + graphics + simulation)
experiment thirty-seven MQ-3 alcohol sensor module ethanol flammable gas sensitive gas high-sensitivity detection alarm sensor probe
Wiring diagram of Arduino experiment
[Arduino] 168 sensor module series experiments (data code + simulation programming + graphics programming)
Experiment 37: MQ-3 alcohol ethanol sensor module (semiconductor surface resistance control type)
Item: The normal value is less than 1, alcohol is detected, the value is greater than 3
Arduino experiment open source code
/*
【Arduino】168种传感器模块系列实验(资料代码+仿真编程+图形编程)
实验三十七:MQ-3酒精乙醇传感器模块(半导体式表面电阻控制型)
项目:正常数值为小于1,检测到酒精,数值大于3
*/
const int gasSensor = 0;
void setup() {
Serial.begin(9600); // sets the serial port to 9600
}
void loop() {
float voltage;
voltage = getVoltage(gasSensor);
Serial.println(voltage);
delay(200);
}
float getVoltage(int pin) {
return (analogRead(pin) * 0.004882814);
// This equation converts the 0 to 1023 value that analogRead()
// returns, into a 0.0 to 5.0 value that is the true voltage
// being read at that pin.
}
Screenshot of experimental serial port output
The output waveform of the experimental test
Experiment with open source graphics programming (Mixly, Mind+, learn by playing)
Experimental serial port return
Arduino experiment scene diagram
Appendix: Types and Functions of Gas Sensors
MQ-type gas sensors consist of several types according to their respective names. The list below shows the capabilities of each gas sensor.
MQ-2: Liquefied petroleum gas/smoke detection sensor
MQ-3: Alcohol detection sensor
MQ-4: Methane gas detection sensor MQ-5
: Liquefied petroleum gas Liquefied petroleum gas sensor (natural gas, city gas)
MQ-6: Liquefied petroleum gas LPG sensor (propane, butane)
MQ-7: carbon monoxide gas detection sensor
MQ-8: hydrogen gas detection sensor
MQ-9: gas detection sensor (carbon monoxide, coal gas, liquefied natural gas)
MQ-135: air quality detection sensor (benzene , alcohol, smoke)
Appendix: References
1. KE3003-29 MQ-3 alcohol sensor
https://www.bilibili.com/video/BV17b4y1o71b/?spm_id_from=888.80997.embed_other.whitelist
2. Application and program design of MQ-3 alcohol sensor ADC analog to digital value
https://www.bilibili.com/video/BV1ob4y1m7BJ/?from=search&seid=1568771185565631741&spm_id_from=333.337.0.0
3. Precautions for using MQ-3 alcohol sensor
https://www.bilibili.com/video/BV1ka4y1L7NH/?from=search&seid=10232272542852011862&spm_id_from=333.337.0.0
4. Alcohol measurement based on STM32 single-chip microcomputer MQ-3 LCD 1602 display voice alarm
https://www.bilibili.com/video/BV1jQ4y1d7oC/?from=search&seid=1568771185565631741&spm_id_from=333.337.0.0
5. Arduino Small Classroom (8) Gas Sensors and Logical Operators
https://www.bilibili.com/video/BV1sz411z7Lc/?from=search&seid=11409017718250724600&spm_id_from=333.337.0.0
6. Arduino-MQ-2 Gas Sensor Detection Demonstration
https://www.bilibili.com/video/BV1Fy4y1V7FF/?from=search&seid=11409017718250724600&spm_id_from=333.337.0.0
7. 【ARDUINO Video Tutorial】16. Smoke sensor experiment
https://www.bilibili.com/video/BV1zJ411h7eN/?from=search&seid=10660080485261479729&spm_id_from=333.337.0.0
8. Drunk detection and anti-drunk driving design based on STM32 microcontroller Alcohol detection system design-MQ-3-LCD602-voice
https://www.bilibili.com/video/BV15Z4y1L7Xp/?from=search&seid=9520844162537660502&spm_id_from=333.337.0.0
9、