Go Down

Topic: Automated Reptile Control System(webserver, Data Logging, RTC and much more) (Read 40 times) previous topic - next topic

alvydas001

Fantastic job! Congratulations!

One proposal, and it will be a perfect system. DS18B20 sensors can be connected on a single cable. It is more convenient.
But then you need to know their address. Here is a sample of how addresses are assigned sensors: http://www.homebrewtalk.com/f51/arduino-networked-temperature-monitor-340294/index2.html#post4286666
The combination of both programs get a great system.

My English is very bad, but I hope you got the idea... :)

wallaceb


Fantastic job! Congratulations!

One proposal, and it will be a perfect system. DS18B20 sensors can be connected on a single cable. It is more convenient.
But then you need to know their address. Here is a sample of how addresses are assigned sensors: http://www.homebrewtalk.com/f51/arduino-networked-temperature-monitor-340294/index2.html#post4286666
The combination of both programs get a great system.

My English is very bad, but I hope you got the idea... :)


i see nothing wrong with your English.

i did think about having them on one bus, however per the Dallas Semiconductor data sheets, a star topology is not recommended. i wanted the least possible issues with the data feedback, and so i choose to have each sensor on its own "one wire master" giving me the best possible electrical setup to reduce error.

and with so many I/O on the MEGA i had no worries about running out of pins.

alvydas001

I have project and use 10 DS18B20 sensors to connected on one cable (parasite power mode). Longest distance of 16-18 meters (2 pieces), 10-12 meters (5 units), the other 3-4 meters. Runs great. The project is here: http://www.saulevire.lt/en (and here- http://www.ksduino.org/?devices&device_id=3331) (works half the year, but the site still has not been made).

zoomkat

Quote
i am also wondering if it is something with the ethernet shield. i have been able to crash the arduino if i purposfully send lots of information over to it really fast. it just stops responding.


I think the 5100 chip is capable of only four sockets, so if a socket is not properly allowed to close, it may become unavailable for future use.

Quote
i am also wondering why my arduino freezes when i have the watchdog enabled. should that not reset the system?


I haven't looked at the watchdog code. Is it a proven design?

Quote
i tried to use the "Wstring.cpp" and "Wstring.h" from Paul Stoffregen's teensey system. everything compiled, but it would no longer function and i have not determined what is causing it to not work.


I think those librarys are included in the latest arduino core design. If you use the string functions, under some conditions it is said that used memory is not automatically released, and might eventually deplete available memory, causing a freeze. Recently various patch solutions have been posted

Consider the daffodil. And while you're doing that, I'll be over here, looking through your stuff.   8)

wallaceb

I have completly removed the string library from my code and replaced it with char arrays. I am testing the code now to see if it crashes, resets, or freezes.

Luckily removing the string class actually saves about 4k of flash and I appear to be using about 600 fewer bytes of SRAM.

I will post the code shortly.

I have found a bug with my "system uptime calculator" where it calculates wrong when transitioning from February to march. I wi have to look onto that issue


draythomp

Go to the playground and look at the Time and TimeAlarms library.  You don't have to actually set the time, but you already have an RTC, so it should be easy to do.  In the Time header file are a lot of macros including days between dates and such.  Also, out on the web are a ton of days between dates routines that you can use.  Most of the samples also have the seconds between date that will work for you as well, although saving the unix time when you start and just subtracting it from the current time will give you seconds pretty easily.
Trying to keep my house under control http://www.desert-home.com/

wallaceb

i have a few other bugs now, because of the removal of strings, my ability to download log files, and to delete the log files no longer works. i will look into that now as well.

edit: those are fixed now  8)

still going to look into the "system up time" calculator


Go to the playground and look at the Time and TimeAlarms library.  You don't have to actually set the time, but you already have an RTC, so it should be easy to do.  In the Time header file are a lot of macros including days between dates and such.  Also, out on the web are a ton of days between dates routines that you can use.  Most of the samples also have the seconds between date that will work for you as well, although saving the unix time when you start and just subtracting it from the current time will give you seconds pretty easily.


thanks for the info, i will take a look at those.


edit: latest code
https://www.dropbox.com/s/4s3vzc5gopik7re/Arduino3-1-2013.zip

mkcinek

Hi,

could you tell me what moisture sensor have you used?

thanks!

wallaceb

i am using http://sensing.honeywell.com/product%20page?pr_id=53944

mkcinek

Hi,


No humidity sensor attached so far, just checking if all relays can be controlled in manual mode
but  for unknown reason humidifier does not turn off in manual mode.
Any ideas ?

thanks!

mkcinek

ps. Talking about RTC, which pin SCL and SDA is connected on the arduino board  please ?

Nick_Pyner

On a standard Uno it is SDA to A4 and SCL to A5. Note that it is pins 20, 21 on a Mega. Most Megas have this marked on the board.

wallaceb


Hi,


No humidity sensor attached so far, just checking if all relays can be controlled in manual mode
but  for unknown reason humidifier does not turn off in manual mode.
Any ideas ?

thanks!



sorry for not responding sooner, been really busy.

to answer your question, i had the same issue. i know i fixed it, and if i recall there is a typo in the version of code i posted. when i get home tonight i will post the latest. that WILL fix that issue.  :smiley-mr-green:


ps. Talking about RTC, which pin SCL and SDA is connected on the arduino board  please ?


i have the RTC connected to pins 20 and 21 on the MEGA



i would also like to update that the random system reboots and freezes have been fixed. now that i have removed the string class the system is stable. i also removed some code that had the unit auto-update its time every 24 hours. without that, you can still get the correct time by manually initiating a time update. the system has now been going for 25 days while logging data without issues.

wallaceb

latest code:

https://www.dropbox.com/s/s1tdkgo04rtc6cj/Arduino_3-29-13.rar

mkcinek

hi,

thanks - manual moisture control works now.

I have encountered another issue, when trying to connect with smartphone, arduino freezes - orange led starts blinking and no response...
Is there a way to use mobile devices with your control system?

Thanks!

Go Up