/* The MQ-3 sensor is used to detect alcohol. It an be programed by arduino. Here, we build a program to identify ethanol vapor. In the MQ-3 sensor, there are four pins. 1. VCC 2. GND 3. DO 4. AO VCC, GND, AO pins are connceted to the arduino. */ int sensorPin = A0; // select the input pin for the MQ-3 sensor int sensorValue = 0; // variable to store the value coming from the sensor void setup() { Serial.begin(9600); } void loop() { // read the value from the sensor: sensorValue = analogRead(sensorPin); Serial.print("MQ3 sensor value: "); Serial.println(sensorValue); delay(1000); }