0_0
Full Member
 
Posts: 114
Raspberry Pi: Yes
Other Device: PC, Arduino, ESP32
|
Post by 0_0 on Mar 30, 2022 6:17:00 GMT -8
Correction:
I thought I had already solved this problem, but it came back.
Problem: Once set up, the lights on my hydro unit (Valve 6) would turn off around every one-to-two hours.
I had been having other problems which turned out to be "low power" related, and by unplugging the power supply from the wall, I was able to solve many of them. The lights remained a problem though. I thought that it was a power drop I saw when some newly installed lights turned on, but after moving the RPi, the problem has returned after a day of no issues.
I am able to use Manual Control to turn them back on, but the same problem reoccurs even if I set the number of seconds to 6 hours (21600 sec). I have the RPi and everything else plugged into a Battery Backup to remove any possible power fluctuation issues.
I'm not seeing it reboot
The water pump (Valve 5) is still running on schedule. All other sensors seem to be working aside from Turbidity, but I need to check the extension that I made for that sensor to verify continuity. SG3Config seems to be saving changes to programming with no problem.
I am about to get an air pump and a USB tester today and will test timing and V/A activity with those as well.
Thank you in advance ~S
Previous post: SOLUTION: I have already solved this problem, but I wanted to post it in case anyone else runs into this issue.
Problem: Once set up, the lights on my hydro unit would turn off around every one-to-two hours.
I had been having other problems which turned out to be "low power" related, and by unplugging the power supply from the wall, I was able to solve many of them. The lights remained a problem though.
Cause: It turned out that the outlet that I had chosen belongs to a circuit which is shared by the outside plugs. My landlord had plugged some new motion activated flood lights in, and it was bouncing my power every time it turned on.
Solution: I resolved this by choosing a different outlet which is shared by my inside appliances, which have debounced switches.
|
|
|
Post by SDL on Mar 31, 2022 9:05:11 GMT -8
Wow! That is great debugging. Thank you for sharing the problem and solution.
We could have spent a lot of time here trying to figure out what was wrong with the software. Always suspect your power when you have weird problems like this!
BP
|
|
0_0
Full Member
 
Posts: 114
Raspberry Pi: Yes
Other Device: PC, Arduino, ESP32
|
Post by 0_0 on Apr 11, 2022 14:31:05 GMT -8
I though that I had the lighting figured out, but it's still turning itself off after 0.5 - 2 hours.
I can use the "Stay On" feature, but there are two problems; 1) even if I put in 16,000 sec and turn it on every hour, it still turns off before the hour is up. 2) There isn't a feature to tell it to stop cycling after a given time or even number of cycles, so it turns itself rhythmically on and a-rhythmically off all night.
I have tried scheduling it as daily, 12, 6, 3, 1 hrs, and down to 15 minutes. I moved the camera to the hydro setup, and I just got my first stop-motion reel of the cycles. It looks like the extender might be stopping every time the lights go off?? It is hard to tell for sure from the sequence of pics.
The extenders and the Pi are all now running through a UPS, and I have metered all power, (both USB and line power), and I see no significant fluctuations on the output side of the UPS. (The input side of the UPS is "normal for OR", where we use some historically dirty hydro power).
I see nothing in the Logs section of the Dash, and nothing of interest in /var/log.
If you have any ideas or have seen this before, I would love some assistance on this one, I'm beating my head against a wall.
On the brighter side; the reel shows how fast heirloom lettuce will grow in hydro environments. You can actually see them growing, not just phototropic movements. That will be great for the blog that I am creating for your guest blog section. I am starting some similar seeds in soil to get a comparison that will illustrate the 3-5x growth speed that hydroponics offer.
I have gotten the Aeorvoir (https://www.aerogarden.com/2020-aerovoir.html) to test it's ability to function with this setup. If it doesn't work, I'll only need to adjust the height of the hydro unit by a few cm or so.
Also, the SolarMax is up and functional. I will be putting an extender on it after this cold snap is over, to tend my raised bed. It will be in a clear "miniature greenhouse" (read: aluminum shelving system with a clear cover and a zippered-door), where the SolarMAX has been located for a few days now. That will keep it more-or-less weather resistant. The clear cover doesn't appear to be interfering with the SolarMax's capabilities so far.
Have a good day and thank you again, ~S
|
|
0_0
Full Member
 
Posts: 114
Raspberry Pi: Yes
Other Device: PC, Arduino, ESP32
|
Post by 0_0 on Apr 11, 2022 14:33:57 GMT -8
Apr 11, 2022 15:05:17 GMT -7 SDL said: Go ahead and post this on the open forum. I'd welcome the community looking at this too. One thing I would like you to do. Look in the database in SmartGarden3->ValveChanges and in valve Record. Find the records that show me your problem and let's look at those items. I turned off the valve changing info to the system log because it cluttered everything up. BP Posted by 0_0 5 minutes ago I xfer this to the community next, but in the mean time; good call once again, sir.  I have a feeling this is our culprit: SELECT * FROM `SystemLog` WHERE ID = 28399 28399 10 1445, 061, reboot, CPU0 reset reason: SW_CPU_RESET... 2022-04-11 14:11:31 Now I just need to figure out "Why?" Cheers ~S 3 minutes ago 0_0 said: I assume watchdog? But again, "Why?"
|
|
|
Post by SDL on Apr 12, 2022 9:05:33 GMT -8
Hmm. Would you give me the SmartGarden3->ValvesChanges and ValveRecords records both before and after that reset? The system is designed to properly recover from a reboot. You should just see short outage when it reboots, then a restoration of the states of the outputs and valves. Sounds like there might be a problem with this. Also PM me both your JSON files.  The ESP32 will reboot occasionally due to (my belief - not proven) instability in the BlueTooth stack and/or network stack. BP
|
|
0_0
Full Member
 
Posts: 114
Raspberry Pi: Yes
Other Device: PC, Arduino, ESP32
|
Post by 0_0 on Apr 12, 2022 9:57:10 GMT -8
It happened at 9:04 today, so I have bookended it from 9:00 - 9:15 am. If you want more, just let me know and I'm happy to oblige. Thank you for the assistance  ~S System Log 29604 35 BC:B0 - Low Moisture: 5 < 6 2022-04-12 09:01:01 29605 35 BC:7B - Low Moisture: 0 < 6 2022-04-12 09:01:01 29606 35 BC:49 - Low Moisture: 1 < 6 2022-04-12 09:01:01 29607 35 05:7E - Low Moisture: 1 < 6 2022-04-12 09:01:01 29608 10 1445, 061, reboot, CPU0 reset reason: SW_CPU_RESET... 2022-04-12 09:04:18 29609 20 Wireless Device ID 5275 Active 2022-04-12 09:04:20 29610 20 Wireless Device ID 1445 Active 2022-04-12 09:04:22 29611 35 04:8A - Low Moisture: 0 < 6 2022-04-12 09:06:01 29612 35 BC:B0 - Low Moisture: 5 < 6 2022-04-12 09:06:01 29613 35 BC:7B - Low Moisture: 0 < 6 2022-04-12 09:06:01 Valve Changes Database SmartGarden3 Table structure for table ValveChanges Column Type Null Default Links to Comments MIME type ID int(11) No DeviceID varchar(10) No ValveNumber int(11) No State int(11) No Source text No ValveType text No SecondsOn int(11) No TimeStamp timestamp No current_timestamp() Dumping data for table ValveChanges ID DeviceID ValveNumber State Source ValveType SecondsOn TimeStamp 2514 5275 5 1 Timer Event 30 2022-04-12 09:15:02 2513 5275 5 1 Timer Event 30 2022-04-12 09:00:02 Valve Record 5217 5275 V00000100 2022-04-12 09:00:31 5218 5275 V00001100 2022-04-12 09:15:01
|
|
|
Post by SDL on Apr 15, 2022 13:39:40 GMT -8
Thank you for the JSON in the PM. I'll set up our system to duplicate the problem. Then we shall find it! I have a suspicion.
Thanks for the data above too.
BP
|
|
0_0
Full Member
 
Posts: 114
Raspberry Pi: Yes
Other Device: PC, Arduino, ESP32
|
Post by 0_0 on Apr 16, 2022 13:05:35 GMT -8
Thank you 
|
|
0_0
Full Member
 
Posts: 114
Raspberry Pi: Yes
Other Device: PC, Arduino, ESP32
|
Post by 0_0 on Apr 29, 2022 11:30:23 GMT -8
I've noticed that when this happens, the extender reboots, but the RPi doesn't. I have the extender on its own UPS, and have monitored the input P with a USB tester. I saw no V nor I fluctuations, unless they were faster than the sample rate (which I can't find) of the cheap USB tester that I got. The boot time on Dash doesn't change, and it remains accessible, whereas, it's down for a noticeable period when I reboot the RPi myself. Thank you, ~S
|
|
|
Post by SDL on Apr 30, 2022 12:33:24 GMT -8
I'm setting up the test today. I think the extender reboots periodically because of a memory leak in the Bluetooth sensors.
But first, I duplicate the puppy.
BP
|
|
0_0
Full Member
 
Posts: 114
Raspberry Pi: Yes
Other Device: PC, Arduino, ESP32
|
Post by 0_0 on May 1, 2022 5:53:07 GMT -8
Nice. Let me know if there's anything that I can do or send. Thank you, ~S
|
|
0_0
Full Member
 
Posts: 114
Raspberry Pi: Yes
Other Device: PC, Arduino, ESP32
|
Post by 0_0 on May 13, 2022 11:48:14 GMT -8
I was wondering about ways to isolate the culprit. I can remove the batteries from all of the BT Sensors and add them back one-at-a-time. I can imagine two possible diagnosis if it happens again after adding one back: 1) The BT Sensor recently added is the culprit 2) The extender reached a limit and it happened again Are either of those plausible?
Thank you, ~S
|
|
|
Post by SDL on May 13, 2022 11:52:06 GMT -8
I think I have duplicated it now. Hope to run a test this weekend. I have devised a test to see if I am right. The issue is that after an extender reboot, SG3 is not properly updating the state of the extender. It's not the reboot, it's the reinstatement. One of the things we have learned about ESP32 systems is you better be able to survive an update. The Bluetooth stack makes it worse, but it still will happen on occasion. Memory leak or fault somewhere in the ESP32 network stack.
If I am right, then there is a fix that can be implemented in Python.
BP
|
|
0_0
Full Member
 
Posts: 114
Raspberry Pi: Yes
Other Device: PC, Arduino, ESP32
|
Post by 0_0 on May 20, 2022 4:42:42 GMT -8
The more I play with it, the more I think that you're correct; - it seems to happen more often if I am changing between pages which collect BT info. - I had several BT sensors stop communicating with no prompting. I had to reinstall them to get them to talk to the system again. (they were across both extenders, and neither extender lost contact with all of its assigned sensors)
Thank you, ~S
|
|
|
Post by SDL on May 25, 2022 19:54:03 GMT -8
Still haven't gotten to that test (actually the test is running, just have to verify my theory). Maybe Friday or Saturday.
BP
|
|