I've already asked for input in the project guidance section but since it's complete now I'd like to present this little hack here.
I've combined my Gamebuino with two DS 1820 digital temperature sensors to make a thermometer that compares outside to inside temperature and sounds alarms when it's time to let cool outside air in or when to close the windows once it's cooler inside.
Quick demo:
The DS 1820 digital temperature sensors use the 1-wire protocol so I'm just connecting them to the I2C ports for convenience, not to actually talk I2C (1-wire also allows multiple parallel devices on one bus, which is why I connected one sensor to each port)
Here's the data sheet for the DS1820 and the 1-wire Library and Dallas Temperature Control Library. The wiring I used is straight forward: GND to I2C GND, VDD to I2C 3V3 and DQ to I2C SDA (which is A4 or Pin 18 respectively) then just include the libraries in the sketch and set up with the right pin
(there's also a handy Fahrenheit conversion function)
Since the 1-wire library can address the sensors by index and the order is determined by their unique id the port I plug each of them into is irrelevant.
I weatherproofed both sensors with the help of a friend who had some molding silicone left over, but next time I'll try coating them in nail polish instead because I assume that's going to dampen the temperature response less than millimeters of silicone.
Curious to hear your thoughts on this or any tips and improvements. -- Peter
Re: Gamebuino Thermometer and cool outside air alert
Sat Jul 25, 2015 11:57 am
Initially I wanted to use a simple thermistor and just map voltage to temperature. I found out that I can't get good accuracy from that. I then looked around for I2C temperature sensors and just found breakout boards or surface mount chips which I can't solder. I found that too bulky/difficult for my purpose The local electronics shop happened to recommend the DS 1820 sensor to me, it won me over because I only need 3 pins (or even only 2 when using parasitic power, but I played it safe) and it's a very compact part with no breakout board that's easy to coat and hang out the window without a case.