Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Robo-Tank v5.20 is Ready
#1
Hi, I have an update available, quite a few things have been added, fixed and improved so lets dig in.

For this update make sure to view the "Update to v5.20" document in the "Update to v5.20 from v5.0x" folder of the download package as this updates has a few things to do.

First I'll list some features that were in v4.2 but didn't make it to v5 yet.
  • Added screensaver option
  • Added screen lock option
  • Added system to sync display with controller
  • Added option to disable controller restart email on system settings page (default has email off)
  • Added option to disable ATO start/stop email on ATO settings page (default has email off)
  • Added option to disable feed schedule emails on Feed settings page (default has email off)
  • Added option to disable maintenance schedule emails on Maintenance settings page page (default has email off)
  • Added sensor parameter output page with 2 optional views (images at the end of post)
There were also some issues fix.
  • Fixed graphs, first entry for day was placed as last entry
  • Fixed N/A on home page box 6, after scrolling N/A didn't appear
  • Fixed "web features enabled" setting on system settings page, option did stay selected on display
  • Fixed custom rules - rule 2+ couldn't be disabled
  • Fixed schedules, if outlet was a heater and then removed the outlet wouldn't auto resume after controller restart or resume button pressed
I also improved and made changes to a few systems however I'm sorry to say this caused me to reset some of your settings when the update takes place. After the update you'll have to setup all your schedules again except for the lights, setup the custom AC outlet icons, setup the heaters/chillers and enable the added option for emails if so desired. The on/off temperatures for the heaters will also be reverted back to 70/72 so be sure to update these as well.

First I changed how all the data sensor is sent to display which is more reliable and if users with older Gen2 boards still have issues I can add delays to slow it down. There are no delays now but if you have issues let me know and I can add an option in the sketch to turn them on.

I also did an overhaul of the heater/chiller system. There was some reported issues so I made lots of changes to simplify things. Everything is still the same on the display for this and it still functions in the same manner.

There was also some problems with schedules that were on/off type. I was going to fix this however this and all the other options for repeating schedules really complicated things and for schedules simple is best as we don't want issues. Later I'm going to create a different system that will strictly handle repeat "schedules" so you can have basic controller for power heads etc... That was basically why I added those features but I've decided it should be different system. This is the reason you will lose all your current schedules. At the bottom of this post I added some updated images for the schedules.

Another nice change is for calibrating flow meters. To start there was an issue with the auto calibration however it required the pulse rate to be set first for the flow meter and an offset was calculated. Now you only need to start the timer and pump a selected amount of water. Once finished the controller will auto generate the pulse rate for the meter. Overall this makes it more accurate and less confusion. In a future update I'm going to convert the dosing pumps to this system as well.

I also added the watchdog back to the controller. This is a timer built into the MCU which will restart the sketch if it freezes for more than 10 seconds. I didn't have this enabled because of the web features, in the past some experienced the controller always restarting because a connection to the network was being attempted. So I have this tied into the setting which enables/disables the web features. If you don't have the web enabled the watchdog is disabled otherwise it runs. Now many who use the web can still use this feature as most networks don't cause any issues so if you would like this you can make a small change to the controller sketch.

Now for the big addition which covers the new energy monitoring AC power bars.

There's 2 ways to access the data, first is using the screen to change the outlets manually which is below.
  • Under each outlet you can view the current power draw and at the bottom you can view the totals for the whole power bar. 
  • It's not stated on the screen but if you press and hold the "Max Watts" it'll reset. 
  • If you press and hold the "hold to change rate" text it'll take you to the main settings page. This can also be accessed by going to settings, hardware and pressing energy power bar
  • If you press and hold the "View Energy Totals" button you get view all the details. You can also add a shortcut on the home page dock to get direct access
[Image: Main_AC_Manual.jpg]

After pressing the "View Energy Totals" button in the screen above or using the optional shortcut on home page you get the following screen. 4 of the views have been condensed for illustration purposes.
  • This page has a menu on the right side to access different info
  • First view is the "Power", here you can view the current data for each outlet
  • 2nd view is "Consumption", here you can view in watt hours how much power has been consumed for each outlet along with the cost. You can see the total for month, day and year
  • 3rd view is "Estimates", this is updated every 24 hours based on the previous 24 hours. You can view an estimate for each outlet and see for day, week and month along with the cost. Currently this is basic as the week and month is simply calculated from the day. I will be changing it so the actual consumption for the week/month is used and then the remaining estimated is added.
  • 4th view is "Alerts", the alarm levels are auto calculated. To setup the alarm you need to visit this page and press the "Train Alarm" button. The view for the selected outlet will change and tell you it's currently going through training. This will last 24hrs, during this period the current load is recorded every 2 minutes and when finished the min and max is found and padded slightly. This will require tuning over time and I will be adding an option to set custom levels. During the training the data is written to the controller SD card so be sure you have it inserted and added the folder during the update.
[Image: Main_Energy.jpg]

The next view is for the overall totals for the power bar, this is accessed from the menu on the right using the "Totals" button. This shows the live data, totals and estimates with cost.

[Image: Main_Energy_Totals.jpg]

The next view is a menu for the graphs and consumption logs and can be accessed with the menu on the right side. If you go to the regular menu for graphs there's a button for energy consumption which brings you here.

There's 3 different graphs, amps, watts and watt hours. The amps and watts record the current power being drawn at that time and the watt hour graph shows a progression through the day as the watt hours add up. The graphs use the current system for other graphs so all the same features are available. You can view daily, weekly, bi-weekly or monthly so you can look for patterns over time.

There's also 2 consumption logs, these are text based and show how much power was consumed for the day or month, images are below.

One downside to all these logs is it takes time to write the data to the SD card. This happens when all the other sensor data is logged so about every 8.5 minutes but if you have an energy power bar connected it can take about 5 seconds to write all the data. During this time the display appears to be frozen so you will probably experience this at some point. It has no effect on the controller only the display and the freeze affects nothing but a slight annoyance if you're doing something and it starts to write to the card. If you don't have the energy power bar it's how it was.

[Image: Main_Energy_Logs.jpg]

Once you select a graph or log type from the above menu you get the following sub menu, each of them share this same view. Here you can select which outlet you want to view or look at the overall power bar. 

[Image: Main_Energy_Logs4.jpg]

The following image is the daily log view, only days with data will appear and sorted by most current day at the top. There's a button to go to the next page when this fills up and you can see on the left side of the button which page is being viewed. Currently it's setup to scroll through the last 365 days. 

At the bottom of the screen on the right side of the "Exit" button you can see which outlet is being viewed. It'll say "Power Bar Totals" if that was selected.

[Image: Main_Energy_Logs2.jpg]

The image below is the monthly log view. Here you can view the totals for the month for each outlet or the full power bar. This is setup to scroll through the last 10 years.

[Image: Main_Energy_Logs3.jpg]

And finally here's the main settings page for the power bar. You can access this by going to settings, hardware and pressing energy power bar. Here you can setup a backup mode which is stored on the power bar and a timer for when it gets activated. If the power bar is disconnected from the controller the timer will start and once it expires the outlets will switch to the mode selected here.

There's 3 options available for each outlet, on, off or no action.

I went back and forth on the "No Action" option and wasn't sure if I should add it or not as there is a catch with this option. 

When the controller changes the state of an outlet the power bar records it, if the power bar is unplugged from the controller that outlet will remain in the last known mode until a connection to the controller is made again. However if the power bar is totally powered down by unplugging from wall and started up it will no longer know what the last mode was so it'll remain off. The last known state could have been saved to eeprom but that would require a save every time the outlet state was changed which would ware out an eeprom. So this must be kept in mind if you use that option. If you have the power bar plugged into a uninterrupted power supply this option would work but you should verify the power bar doesn't actually lose power for a second while the UPS switches on. Also if at any point the power bar lost full power when it turned back on that outlet would be off.

I have an empty box on this page, if anyone can slice the above paragraph into an easy to understand sentence please let me know. For me to explain it I need 3 pages.

The delay has a range of 10 seconds - 255 seconds however the power bar technically has no limit so if you find this isn't enough time I can increase it.

The cost per kWh is currently setup to be sent to all energy power bars connected, one day I may have the option to set different rates on multiple power bars.

[Image: hardware_energy.jpg]

As I mentioned above the schedules were changed, here's an updated list view. 

[Image: schedules_outlets.jpg]

And here's the updated view for setting the schedule. Now you can only create always on, on or off schedules and I added option to set the seconds.

[Image: schedules_outlets3.jpg]

Here's the first page for viewing all the sensor data. This page is dynamic so you only see what's enabled. You can press and hold any of the sensors to reset the min/max.

[Image: Main_Sensors.jpg]

And here's the 2nd view for the sensors. This is nice if everything doesn't fit in the above view and it's cleaner.

[Image: Main_Sensors2.jpg]
Reply to top
#2
I'm doing the upgrade right now, thanks Rob :D
Reply to top
#3
No problem, I hope it goes well.
Reply to top
#4
Display scrren always shows "checking Connections..." and it remains in that state...

Disonnect all the sensors before update ;) Now it works

P.S. The new pages for the Energy Monitor are amzing!! in the newer releases, if you can, it'll be nice to have € instead of $ for us in Europe :D
Reply to top
#5
Glad you got it updated and you like the new screens. I will be adding the Euro symbol soon, first orders went to US so I have time.
Reply to top
#6
I forgot about a new setting I added for the power bars. Anyone with an older power bar will notice with the update on is off and vice versa. This is what you need to do.

Go to settings, hardware, equipment connected, view addons, and press the edit options button beside the power bar. On the screen that loads you'll see a setting for power bar version. Change it to version 1 and you'll be back in business.
Reply to top
#7
Updated the display and controller and the controller got caught in a reboot loop.  In the serial monitor, it showed connecting to router for a few seconds then would reboot. I had to modify the if statement in the startInternet method to have it skip that section.

I'm not sure if the web is enabled on my controller or not, however, the Ethernet cord is currently plugged into the controller but not connected to any router (i use powerline adapters and it's currently not connected)

UPDATE: Good news!  Clicking around the "Update" screen allowed me to start the update.  I had changed the UTouch.h file to use the one from the Calibration files section and it threw off the hitboxes.  Restored the original and all is well.  Please ignore below

It seems that I'm unable to initiate the update.  Display is showing:
Update Available! but when I click on the OK button nothing seems to be happening.  I waiting 10 minutes or so after clicking it the first time but its still displaying the same update screen on the display.  It does seem to briefly flash and redraw the display upon clicking OK for the first time however.  Serial monitor for the controller shows:

Starting Robo-Tank v5.20
Initializing sd card...
SUCCESS - sd card initialized.
SUCCESS - Found index.html file.
This should read 50: 50
Starting Controller -------------------
Internet is not enabled
Startup Complete ----------------------2715

Serial monitor for the display shows:

Starting Robo-Tank v5.20
Initializing sd card...
SUCCESS - sd card initialized.
SUCCESS - Found robotank.raw file.
Eeprom Test - This Should Read 50: 50
Starting Controller -------------------
Reply to top
#8
Interesting... someone else is having similar issues. I have to imagine the reboot loop is happening because the watchdog timer. If the Due doesn't cycle once in 10 seconds it will auto reboot but you'll see on line 235 of controller sketch that it only gets enabled if the web is disabled. I did that because sometimes the web can tie the Due up for over 10 seconds but that can't happen without the web. I just did some more testing with the watchdog and the timer starts fresh when it's enabled so even if it took 30 seconds to connect to router and watchdog still enabled the timer doesn't start till after it connects to router. At that point it would be ok until it went to check for IP and possibly happen then if the server doesn't respond. But with all that said the watchdog shouldn't be turned on if web is enabled and if web is off then there should be no issues.

Can you try the following as I can't replicate the problem.

In the controller sketch comment out line 235 by adding // to the beginning of the line.

Then upload and see if it starts up ok. If it does then go to settings, system and cycle the web enabled setting as there was a minor issue previously so maybe it's causing the issue. After doing that restart the controller and verify in the serial monitor that is says "Internet is not enabled". After that remove the // from line 235 upload again and see if it starts up. If it does enable the web features again and restart the controller (press and hold top right corner) and see if it starts up ok.
Reply to top
#9
(07-10-2019, 08:47 AM)midwestE Wrote: UPDATE: Good news!  Clicking around the "Update" screen allowed me to start the update.  Seems the hitbox was pretty far off on my display! Please ignore below

We were typing at the same time. :) So everything is ok now?
Reply to top
#10
Yes, I had swapped the configuration file Utouch.h in my arduino files and apparently it's not there right one. The original works fine
Reply to top
#11
Ah well glad to hear you figured it out.
Reply to top
#12
(07-10-2019, 09:20 AM)Rob F Wrote: Interesting... someone else is having similar issues. I have to imagine the reboot loop is happening because the watchdog timer. If the Due doesn't cycle once in 10 seconds it will auto reboot but you'll see on line 235 of controller sketch that it only gets enabled if the web is disabled. I did that because sometimes the web can tie the Due up for over 10 seconds but that can't happen without the web. I just did some more testing with the watchdog and the timer starts fresh when it's enabled so even if it took 30 seconds to connect to router and watchdog still enabled the timer doesn't start till after it connects to router. At that point it would be ok until it went to check for IP and possibly happen then if the server doesn't respond. But with all that said the watchdog shouldn't be turned on if web is enabled and if web is off then there should be no issues.

Can you try the following as I can't replicate the problem.

In the controller sketch comment out line 235 by adding // to the beginning of the line.

Then upload and see if it starts up ok. If it does then go to settings, system and cycle the web enabled setting as there was a minor issue previously so maybe it's causing the issue. After doing that restart the controller and verify in the serial monitor that is says "Internet is not enabled". After that remove the // from line 235 upload again and see if it starts up. If it does enable the web features again and restart the controller (press and hold top right corner) and see if it starts up ok.


I restored 5.20 to original and it rebooted after "Connecting to Router++++++++++++++++++++++++++++++++++++"
I then commented line 235   //if (web.webEnabled() == 0) watchdogEnable(10000); and still the same reboot loop.
Reply to top
#13
Can you comment out line 234 as well and see if it starts. If it does then go disable web as described and uncomment these lines again and see what happens.
Reply to top
#14
(07-10-2019, 09:52 AM)Rob F Wrote: Can you comment out line 234 as well and see if it starts. If it does then go disable web as described and uncomment these lines again and see what happens.
Reply to top
#15
Sorry for the late reply, something came up and I couldn't be around.

Your message didn't post Dom but I assume it's same issue. I just removed the watchdog timer and uploaded 5.20 again so anyone having issues try downloading again and uploading.
Reply to top
#16
I'll try the procedures you posted above today and see what i find. Sorry I had a few things come up and couldn't test anymore
Reply to top
#17
No problem, I think it will be ok now, this is the same thing that happened last time I enabled the watchdog but this time it should only be enabling if web is disabled. I'm kind of confused as no matter what I do on my end I don't get any of these problems and never have. So I'm pretty confident it'll be ok now.
Reply to top
#18
(07-10-2019, 09:52 AM)Rob F Wrote: Can you comment out line 234 as well and see if it starts. If it does then go disable web as described and uncomment these lines again and see what happens.

I added Serial.println(web.webEnabled()) above 234 so I could see what value it had.

Commenting 234-235:
  • web.webEnabled() = 1
  • Controller started without issue
Turned of web features in on the display:
  • Controller rebooted immediately after changing that setting
  • Uncommented 234-235
  • web.webEnabled() = 0
  • Controller started without issue
Reply to top
#19
Thanks, now that it's running 5.20 what happens when you enable the web again and do a restart?

webEnabled should = 1 and the watchdog shouldn't be enabled. That's where it gets strange, it appears the watchdog is still being enabled because when it's 1 like it was originally this should have never happened.
Reply to top
#20
I noticed an issue with the new feeding method additions in feed.h.  The "Hand Feed" button now will initiate the autofeeder as if I had hit the "Auto Feed" button.

(07-12-2019, 07:05 AM)Rob F Wrote: Thanks, now that it's running 5.20 what happens when you enable the web again and do a restart?

webEnabled should = 1 and the watchdog shouldn't be enabled. That's where it gets strange, it appears the watchdog is still being enabled because when it's 1 like it was originally this should have never happened.

After re-enabling the web features and rebooting, it will reboot loop again
Reply to top


Possibly Related Threads…
Thread Author Replies Views Last Post
  Robo-Tank ATO System - Standalone Product Rob F 22 490 Yesterday, 01:42 PM
Last Post: Rob F
  Robo-Tank Hardware Expansions Coming Soon Rob F 13 428 Yesterday, 01:36 PM
Last Post: Rob F
  Robo-Tank v5.13 is Ready Rob F 61 3,353 06-19-2019, 12:30 AM
Last Post: Rob F
  Robo-Tank v5.12 is Ready Rob F 34 2,135 04-30-2019, 12:35 PM
Last Post: fietsenrex

Forum Jump:

Current time: 11-11-2019, 07:13 PM