GithubHelp home page GithubHelp logo

some question... about arduino-mq131-driver HOT 1 CLOSED

ostaquet avatar ostaquet commented on September 27, 2024
some question...

from arduino-mq131-driver.

Comments (1)

ostaquet avatar ostaquet commented on September 27, 2024

Hi,

A lot of questions ;-)

1° Preheat and calibration are two different operations.

Preheating is burning the heater to remove all residues of the fabrication process. The preheating is just supply 5V on the heater for 48 hours in order to have the sensor reading to work.

Calibration process is to define the R0; meaning defining the resistance of your sensor when there is no ozone in the air. The best is to make the calibration in fresh air during a Sunday (less traffic and less pollution). The R0 will be used as basis to measure the concentration.

2° The heater needs around 5V to heat properly. According to some experiment I saw on the internet, the voltage is not critical as far as the heater is heating. I use a BC337 because I have some of them on my desk ;-). You can use any NPN transistor as far as you sature the base. On my side, I have around 4.5V (5V minus the voltage drop of the transistor). Normally, the heater should be warm after some seconds. If not, your wiring is probably problematic or you are not saturating the base of the transistor.

3° The analog value that you are reading is the resistance of the sensor (Rs). In order to measure the concentration, you need to know the resistance in fresh air (R0, coming from the calibration) and compare the delta with the Rs. After that, the ratio Rs/R0 is used to determine the effective concentration based on the datasheet. The idea is to find a formula to calculate this. You can find the Excel file in the repository to see how it was calculated for the driver (see https://github.com/ostaquet/Arduino-MQ131-driver/blob/master/datasheet/Sensitivity_curves.xlsx)

As said above, if you don’t have full 5V, it is not a problem but the heater has to be warm. If not, there is another issue.

4° The time to read could be long depending on the variability of the sensor. One solution is to be more flexible with the counting of stable value before considering as stable. In the driver, we are expecting 20 times the same value on the Rs to consider this as stable. By changing the parameter MQ131_DEFAULT_STABLE_CYCLE, you can limit the number and speed up the process (with a risk of being less accurate ;-) ).

5° It sounds like normal values if you are living in a healthy environment ;-). 48h of calibration is quite long, I guess you’re talking about the preheat time ;-). I never got 5V on the heating pin except if I push the voltage on the heater circuit at 5.6V to compensate the voltage drop in the transistor.

2.5V on heater seems very low to me. It explains probably why your timing to have a stable value is so long. The nature of the sensor is to detect burning gases that are burn with the sensor... if the heater is not so warm, it takes time ;-)

4.7Kohms or 5.1Kohms doesn’t matter if you saturate the transistor but the 2.5V on the heater seems a bit low. If you’re using a 9V battery, it is probably the problem. Try using a stable power supply unit if you’re using the battery ;-)

Hope it helps ;-)

from arduino-mq131-driver.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.