Get right values from Carbon Monoxide (MQ7) and ambient light (PT550) sensors

Hi, I bought these two sensors, but I don't how to get the right values in ppm (carbon monoxide) and lux (light sensor), both only use the analogRead function with the supply pin connected to the 5V pin on Arduino

DFRobot Carbon monoxide sensor Datasheet

DFRobot Ambien light sensor v2 Datasheet

I'm using UNO R3

Please help as your assistance will be highly appreciated.

regards, Alvaro

Alvaro/ The optical sensor is the easiest. Connect pin 1 to +5V, pin 3 to a resistor with the other end connected to ground. Connect your analog input to pin 3 also. Choose the resistor depending on the light level you want to detect- lower light levels need higher values. Maybe start with 1K resistor and check the readings between dark and light. Be aware that the sensor you have bought is much more sensitive to red light than to blue light.

The MQ-7 is harder. You cannot just connect it to 5V, the supply voltage must be switched between 1.4 and 5V as shown in Fig 5 on the data sheet. Did you check this link http://playground.arduino.cc/Main/MQGasSensors ? Also be warned that the readings are sensitive to temperature and humidity so you will need to compensate for those if you want accurate and stable readings.