Posts | Comments

Planet Arduino

Archive for the ‘alcohol sensor’ Category

Ott
18

MQ-3 Alcohol Sensor, Breakout Board + Arduino

adafruit, alcohol, alcohol sensor, arduino, Gas, gas sensor, sparkfun, tutorials Commenti disabilitati su MQ-3 Alcohol Sensor, Breakout Board + Arduino 

A lot has happened since our last article was published and to celebrate the continuance of bildr we’ll be playing with the MQ-3 Alcohol Gas Sensor. Coupled with the SparkFun Gas Sensor Breakout Board, connecting the MQ-3 to your Arduino is a breeze.

The MQ-3 is a heater-driven alcohol sensor that outputs an analog signal (usually interpreted somewhere between 150 and 1023 depending on how long you let the sensor warm up), which through the use of your Arduino code and calibration, can be interpreted for whatever use you need.

Putting The Pieces Together

When attaching your MQ-3 to the SparkFun Breakout Board, it should be noted that it doesn’t matter which way the MQ-3 alcohol sensor is pressed in. Both the A pins are electronically the same as well as the B pins. The center pins on both sides are the heater element pins. Since the circuit will be running on +5V DC it doesn’t matter which way the sensor is soldered to the board. As long as you have the SparkFun logos and pin labels facing downward, so you can still see them when the sensor is flipped over, you are good to go!

Note: Again, the MQ-3 is heater-driven so be aware that the sensor will become warm and may even emit a smell at first. This is completely normal.

Calibration: If you take your time, you can find out what values equate to specific percentages or even blood alcohol concentration in the case of a breathalyzer. You will of course need to calibrate your MQ-3 based on your specific Arduino code since sensor readings will vary. Although I can’t help with your specific calibration scenario, the best advice I can give you is to use several isopropyl alcohol bottles at different percentages for your testing. Do NOT get the sensor wet with alcohol! Simply squeeze to breathe the vapors of the alcohol into the sensor and take your readings.

mq3-arduino-hookup

Code

The Arduino code for this is very simple if you just want to view the raw data.

int mq3_analogPin = A0; // connected to the output pin of MQ3 

void setup(){
  Serial.begin(9600); // open serial at 9600 bps
}

void loop()
{
  // give ample warmup time for readings to stabilize

  int mq3_value = analogRead(mq3_analogPin);
  Serial.println(mq3_value);

  delay(100); //Just here to slow down the output.
}
Unless otherwise stated, this code is released under the MIT License – Please use, change and share it.
Dic
26

Buzzed Buzzer gives you a Breathalyzer test while ringing in the new year

alcohol sensor, arduino hacks, breathalyzer, buzzer, mq-3, New Year's Eve, Teensy Commenti disabilitati su Buzzed Buzzer gives you a Breathalyzer test while ringing in the new year 

alcohol-sensing-party-buzzer

We’re not sure if there’s enough time to get a parts order┬ádelivered, but no geeky New Year’s party will be complete without a party buzzer that doubles as a Breathalyzer. The Buzzed Buzzer hides all of the necessary bits inside of a paper and plastic party favor. We guess it only buzzes if you’re over the limit? Actually that’s not the case at all. The accuracy of the sensor used in the project really just measures the presence of alcohol and can’t quantify BAC.

A Teensy 2.0 microcontroller board drives the project. Powered by a Lithium cell, it monitors an MQ-3 Alcohol gas sensor and drives a buzzer. The components are just small enough to be hidden by the cone of the party buzzer. You can see a demonstration of this in the short clip after the jump.

This is a fun project, but we’re still big fans of getting the crowd involved with this large LED meter which is hooked up to the same style of alcohol sensor.

[via Dvice]


Filed under: arduino hacks


  • Newsletter

    Sign up for the PlanetArduino Newsletter, which delivers the most popular articles via e-mail to your inbox every week. Just fill in the information below and submit.

  • Like Us on Facebook