Congratulations Richard R, for answering the question and has received an EZ-Credit award! Share what you have learned and create a tutorial to help others by clicking here.

Temperature And Smoke Detection Senors With Ez-b V4

Assistance Requested

Help Steve G with their question and receive $10 of EZ-Credit to get more robots and parts from our store. The following information was provided about their previous efforts searching tutorials for a resolution.

Steve G claims to have checked these sources:

User-inserted image

Hi guys.

I need a little advice on some additional sensors I was thinking of adding to my bot, and as I am still waiting for my dev kit and extras to arrive, I am unable to test what I am thinking of doing so I'm hoping someone can point me in the right direction.

I had an idea of adding a smoke detection sensor and maybe a temperature sensor as well. The idea being that if I ask the bot what the current temperature is, or if the bot detects smoke or Co2 fumes, the bot would respond with verbally with a pre-recorded MP3 file of the Cepstral voice I have, or one better, have my bot tell me what room the smoke or gas is detected in. Here are a couple of links to what I am thinking of adding.

Smoke detection sensor

Temperature sensor

Would these sensors be compatible with the EZ-B v4 and 7.4 LiPo battery? I see that the temperature sensor is compatible with Arduino so I am hoping that both of these sensors will play nice with the v4. Also, has anyone tried something similar to what I am thinking of doing? As always, any help or advice anyone can offer would be greatly appreciated.


Steve. Winky

I have found a few conversations, tutorials and activities that may help with your question. Take a look at these links. I've sorted them by what I believe to be most relevant but that is not always the case as I'm still learning.

Also, consider reviewing the Learn section for informative lessons and activities. Check it out!


You will need voltage regs for most sensors if powering the EZB4 above 5v... Most sensors are 3v or 5v... If they are compatible with the arduino then most likely they will be compatible with the EZB4... The sensors you have listed here will need to use a serial interface most likely (If you have their data sheets we can confirm)... In this case you can use one of the 3 UART ports on the ezb4 to read them...


The DHT11 is a serial device so must be connected to a UART port. It's quite complicated to get the data out of too. I use one on an Arduino as there is a library written for it for Arduino, I'm yet to find the time to attempt to port it over to EZ-Builder.

There isn't much info on the smoke sensor, I'll need to see if I can find a decent datasheet or arduino library for that before I could comment on it's suitability.


Thanks for the replies guys.

So it doesn't sound as easy as I first thought it might be. The only info I have on these sensors is what is on the sales pages, no data sheets.

The links I supplied were only examples of what I was thinking of getting, but if there is something else out there that would be v4 compatible that anyone knows of, I'd love to know.

Steve. Smile


I just spoke with Jeremie today and we will have the 5 volt regulator ez-bit in the store within 2-3 weeks


That's great to hear DJ. So could you tell me, with the 5v regulator EZ bit, would using the sensors I mentioned be easy to use with the v4? If so, how would I go about scripting or coding these sensors to work the way I would like with a verbal response?



Short of coding it for you, it's all in ezbuilder including examples... below are some of the commands you would need to use.... I used these successfully to communicate with a Roomba...

Just give it a shot yourself... If you get really stuck you can ask here....




Thanks Richard. I'll have a look at the examples and see what I can make of it. So you reckon these sensors will work with the v4 then? I know you said about the temp sensor may work with the v4 as it's compatible with arduino, but there was no mention on what the smoke/gas detector sensor would work with.


The gas sensor (methane, natural gas etc) may be analog.... Again, you may have to find a data sheet to confirm this... As I said, if it works with an arduino, chances are it will work with the v4... I do realize a lot of these Chinese sensors come without info on how to use the... which is of course frustrating...

Sorry I can't be more help than that....


No problem Richard. I found this gas/ smoke detection sensor which I think is the same (or very similar) to what I linked to in my first post, that has a data sheet that are both linked below...

Smoke/gas detection sensor for Arduino

Smoke/gas sensor data sheet