Page 1 of 1

Multiple MQ-X sensors (TTL) possible?

Posted: Tue Feb 25, 2020 4:10 am
by CostasVav
I am working on a project and I wish to have multiple MQ-X type sensors working on a Raspberry Pi 4. I have an order of 10 different gas sensors arriving, all with both analog and digital (TTL) output. Most important are the Methane, CO and H2S sensors.

It seems that the RPi has only 1 serial connection exposed through GPIO. I also have ordered a single USB-to-TTL adapter. Will I need to have 10x USB adapters? I thought I read that only 1 adapter works at a time, but correct me if I am wrong.

What would be the best approach to reading the TTL signal from all 10? Would I need a special microprocessor or an Arduino?

Thanks for any help!

Re: Multiple MQ-X sensors (TTL) possible?

Posted: Tue Feb 25, 2020 11:48 am
by markkuk
The digital output from typical MQ-X sensor boards is a simple on/off signal that indicates if the sensor output is over a treshold set with a potentiometer on the board. "TTL" refers to voltage levels used on the connection. The USB to TTL serial converter you ordered is useless with the MQ-X sensors. If you want actual numerical gas concentration results from the sensors you need a 10-channel A/D converter, for example three ADS1015 boards.

Re: Multiple MQ-X sensors (TTL) possible?

Posted: Tue Feb 25, 2020 8:38 pm
by CostasVav
Thanks for the information, markkuk! I was suspicious that this was the case.

As the voltage from the MQ-X is 5V, I will need a 5V-3.3V shifter circuit between the sensor and A2D circuit, correct?

For a MQ-X sensor, would you think an MCP3008 would be enough, or go up to an ADS1015 or even 1115? Seems to be a tradeoff between accuracy and frequency.