DYI Open Source Arduino bin temp reader project **help** - The Combine Forum

 8Likes
Reply
 
LinkBack Thread Tools
post #1 of 37 (permalink) Old 04-11-2017, 02:20 PM Thread Starter
Senior Member
 
Join Date: May 2011
Posts: 170
Mentioned: 0 Post(s)
Quoted: 23 Post(s)
DYI Open Source Arduino bin temp reader project **help**

Intro:
I've been working on a grain bin temperature monitoring project for a few years now. So far, the prototype temperature readers have only been deployed around my own farm and one of my cousin's farm. There's already some potential for me to assembly more boxes and deploy them at other cousins' and neighbors' yards and likely a lot more interest would be generated if I had something to show/demo. I'd like to take this project to the next level in few different ways. I'd appreciate project guidance from anyone with experience to share.

1. Focus on one hardware setup for the readers (micro controller, wifi chip, solar charger, project box etc) to minimize assembly time and bring the hardware development out of the beta phase.

2. Release my code as open source, free for others to use & modify in the hopes of getting better code developed.

3. Get a better server/backend setup.


More history/background info
Temperature Readers:

I've been using Arduinos for reading OneWire DS18B20 temperature sensors. There can be anywhere from one OneWire bus with 6-20 sensors to four buses each with several sensors. Some readers are continually powered by the grid, these readers just sit there continually reading all the sensors that they detect waiting for an update request from my server. Some readers are battery powered with solar recharging. These readers I'm tried to implement a sleep mode on the Arduino and wifi chip so that they are only "on" for approx. 24 secs for each 2 min update period. Two minute update periods are actually plenty/too fast for a production environment, but while debugging/developing it's nice not having to wait 5, 10 or 30 minutes for the sleeping reader to wake up.

I've had the most experience running my battery powered readers directly off of one 18650 Li-ion cell (3.6-4.2V) and charging that cell via solar with a TP4056 single cell Li-ion charger chip, mostly using cells reclaimed from used laptop battery packs. With a good battery, the readers can keep operating for 5-7 cloudy days and recharge in 1-2 sunny afternoons. Our cold winter temperatures do have an impact on how long the battery lasts. For these solar readers, running directly off the battery, I was monitoring the battery's voltage with the Arduino and having the Arduino sleep indefinitely once the battery's voltage dropped too low. Now recently, I've acquired a few different circuit boards that are designed for single cell lithium battery packs. These circuits have a li-ion charger chip, and a booster circuit to bring the cells voltage up to USB 5V level for output. Some of these circuits also have low voltage protection, which makes cell voltage level monitoring a bit more difficult. The reason for wanting 5V is to run the DS18B20s at higher voltage and hopefully overcome some of the interference I've been battling on the OneWire bus, most of the interference comes from 3 phase inverters running our aeration fans. I've experienced the interference through both the Arduino's power supply and through the 1wire bus.

Wifi/Ethernet:
Originally I started off using a WRT54G router running dd-wrt and ser2net to connect each Arduino with my wifi, some Megas and some Uno variants . Then I also tried some iTead iBoard Arduinos (https://www.itead.cc/iboard.html) which is an Uno with onboard W5100 Ethernet. These boards run at 3.3V and they work decently (simple PoE is nice) until the fan kicks in so I didn't use them very much. I've also used a USR-TCP232-T (replace by T2 UART Serial Ethernet Modules | USR IOT) TTL serial to Ethernet server and now lately, a USR-Wifi232-T (Wireless WiFi Modules | USR IOT) TTL serial to wifi server. With these last wifi modules, I've been using a 3.3V LDO regulator with an enable pin so that I can completely power down the wifi module because I was not able to put it to sleep with any real power savings.

Server/backend:
My backend server is Ubuntu server, running multiple different Perl scripts. One Perl script, triggered by multiple cronjobs (each one specifying a different reader IP, port, etc), connects to each reader and requests a temperature update. When the reader replies, the data is stored in a RRD (round robin database). My web page consists mostly of a bunch of Perl scripts that dynamically generate HTML as needed according to the context required. I have it setup to handle multiple different "yards", each with 1-255 bins, each bin with the potential for 1-255 sensors. Sensors can be selected/deselected for display on each bin's graphs and bins can be named via the web page.

Other background:
Solar panels, cheap sub $10 panels from eBay, 5-6V approx 4x5"
Project boxes, $10 4x4x2 PVC boxes by Carlon/Kraloy
Battery holders, originally soldered in but recently moved to a 2 cell holder (1 x 2*18650 Cell Battery Holder Case Box Leads Pins PCB Board Mount Plastic | eBay)

Goals
Near term goals:
1. Find a single circuit micro controller/wifi combo with or without solar charging capabilities. A shield style setup would also be acceptable.
My wish list:
5V operation for the DS18B20 sensors
Wifi connectivity with deep sleep or powered down
Minimal soldering
Battery powered
Solar charged
Excellent sleep mode
Monitor battery level


2. Learn how to use git-hub and release code into the wild.

Long term goals:
Switch my database/storage over to some system that allows for a nicer user dashboard, with customizable views, email alerts, etc.


m_elias is offline  
Sponsored Links
Advertisement
 
post #2 of 37 (permalink) Old 04-11-2017, 09:39 PM
Senior Member
 
wetfarmer's Avatar
 
Join Date: Jul 2010
Posts: 1,175
Mentioned: 1 Post(s)
Quoted: 114 Post(s)
Wow. The next generation of on farm cobbling. Makes my old brain hurt!



To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
wetfarmer is online now  
post #3 of 37 (permalink) Old 04-11-2017, 09:58 PM
Junior Member
 
Join Date: Sep 2010
Posts: 19
Mentioned: 0 Post(s)
Quoted: 8 Post(s)
I use the ESP8266 Thing and DS18B20 sensors to do bin temperature monitoring. It has a deep sleep mode to save the battery. I have it set to report twice a day to a server program on my PC. It is solar powered and can do about 12 bins for each control box.
dcox is offline  
Sponsored Links
Advertisement
 
post #4 of 37 (permalink) Old 04-11-2017, 10:04 PM
Senior Member
 
BrianTee's Avatar
 
Join Date: Aug 2012
Location: Vermilion Alberta Canada
Posts: 2,416
Mentioned: 0 Post(s)
Quoted: 948 Post(s)
My suggestion would be to put together the code, schematics, and building tips to build a very simple system. One where you walk up to the bin, plug it in, it tells you the temp of the sensors in the bin.

That way, people won;t run away screaming when they hear routers and servers and.....

I know for me personally i would be extremely super duper pooper interested in this. Sharing ideas like this is what it is all about. So yup, a standalone system with code and fritzing diagram, and schematic, and a video how you built the cable would be so very awesome. Oh, and it needs a catchy name. And then once the basics get working, build upon the base system with wireless and monitoring.

Just my $0.02

Did i mention this would be super cool if you could do this?
Hillbillyreefer likes this.
BrianTee is online now  
post #5 of 37 (permalink) Old 04-11-2017, 10:57 PM
Senior Member
 
Join Date: Feb 2010
Location: Alberta
Posts: 165
Mentioned: 0 Post(s)
Quoted: 9 Post(s)
I simply buy thermocouple cable and solder the ends together. Put multiple cables at various heights and locations in the bins. Also have some built up on 1/2 rigid aluminum conduit for portability. Purchased a $200 data logging thermocouple thermometer, and just plug each cable end into it and view. Simple and cheap. I quite enjoy driving around the country to different bin yards and checking on them from harvest through to ship out. It actually works quite well as you can see temps begin to rise (or not) then move the grain if needed.
BrianTee likes this.
jrsharpe is offline  
post #6 of 37 (permalink) Old 04-12-2017, 12:25 AM
Senior Member
 
dfarms11's Avatar
 
Join Date: May 2012
Location: Camrose, Alberta
Posts: 261
Mentioned: 0 Post(s)
Quoted: 20 Post(s)
Very interested in this as well
dfarms11 is offline  
post #7 of 37 (permalink) Old 04-12-2017, 10:09 AM Thread Starter
Senior Member
 
Join Date: May 2011
Posts: 170
Mentioned: 0 Post(s)
Quoted: 23 Post(s)
Quote:
Originally Posted by dcox View Post
I use the ESP8266 Thing and DS18B20 sensors to do bin temperature monitoring. It has a deep sleep mode to save the battery. I have it set to report twice a day to a server program on my PC. It is solar powered and can do about 12 bins for each control box.
I have a few ESP8266s kicking around waiting for spare time. Are you talking about the Sparkfun ESP8266 Thing https://www.sparkfun.com/products/13231? Any reason not to start using the new ESP32 instead?

Sounds like you are building your own cables, do you find any irregular readings from time to time due to EMI? I've found the OPI cables to be more stable than my own when they're in a noisy environment. I think the OPI cable may have a small capacitor by each sensor.
m_elias is offline  
post #8 of 37 (permalink) Old 04-12-2017, 10:24 AM Thread Starter
Senior Member
 
Join Date: May 2011
Posts: 170
Mentioned: 0 Post(s)
Quoted: 23 Post(s)
Quote:
Originally Posted by dcox View Post
It is solar powered and can do about 12 bins for each control box.
Do you use one IO per bin? What value of pullup resistor on the data line have you found to work well?
m_elias is offline  
post #9 of 37 (permalink) Old 04-12-2017, 01:26 PM
Junior Member
 
Join Date: Sep 2010
Posts: 19
Mentioned: 0 Post(s)
Quoted: 8 Post(s)
Yes that's the one. When I started my project the ESP32 wasn't available. I think some of the ESP32 is not implemented yet, such as wifi server. https://learn.sparkfun.com/tutorials...g-hookup-guide

I am building my own cables and haven't found many irregular readings. I found one sensor that was consistently out by about 20 degrees so on the bin report I have a setting to adjust each sensor if needed.

I use on IO per group of about 6 bins with 2 sensors in each bin. I have it set up for 2 groups per control box. I had problems reading with the 4.7 K ohm resistor on longer runs. I found a 2 K ohm resistor worked better.

You can see the project at https://github.com/SK21/TempMonitor/
torriem and BrianTee like this.
dcox is offline  
post #10 of 37 (permalink) Old 04-14-2017, 11:18 AM
Junior Member
 
Join Date: Sep 2010
Posts: 19
Mentioned: 0 Post(s)
Quoted: 8 Post(s)
What happens when the fans kick in, do you loose connection?

dcox is offline  
Sponsored Links
Advertisement
 
Reply

Quick Reply
Message:
Options

Register Now



In order to be able to post messages on the The Combine Forum forums, you must first register.
Please enter your desired user name, your email address and other required details in the form below.

User Name:
Password
Please enter a password for your user account. Note that passwords are case-sensitive.

Password:


Confirm Password:
Email Address
Please enter a valid email address for yourself.

Email Address:
OR

Log-in









Human Verification

In order to verify that you are a human and not a spam bot, please enter the answer into the following box below based on the instructions contained in the graphic.



Thread Tools
Show Printable Version Show Printable Version
Email this Page Email this Page



Posting Rules  
You may post new threads
You may post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

 
For the best viewing experience please update your browser to Google Chrome