-
-
Notifications
You must be signed in to change notification settings - Fork 81
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Low battery voltage if wifi disconnected. #220
Comments
Hello, this is a strange one! I can't recreate this issue on my test rig. As you would expect, the WIFI code has nothing to do with the communication or alarm monitoring over the CANBUS to Victron. How are you powering the controller? Is this directly from the battery? How do you test for lost wifi - do you simply switch the router off? Can you capture the text/log output of the USB serial port on the ESP32 ? |
Does MQTT still run over Wifi to IOBroker or something? |
Thanks @JochenSchmidt for the nice hints :) VE.Bus System [276] | Automatic monitoring | Low battery: Alarm Which is very strange because the battery was never below 60%... |
@Linusten |
I am Testing the newest commit, will update you if the error occurs. -> https://github.com/stuartpittaway/diyBMSv4ESP32/actions/runs/5476905297 |
+1 on @JochenSchmidt comment! system: multiplus II (3000/24, firmware v5.02) connected via MK2 to rpi 3B+ running Venus large pre 3.00 betas and diyBMS on canbus to rpi. Also a Victron MPPT and 600W solar connected to the rpi. A few months ago, upgraded diyBMS to latest and rpi to VenusOS 3.00 release Large Couple of days ago, upgraded multiplus II from 5.02 to 5.05 firmware. No locking of diyBMS or anything getting offline and messing settings with no BMS found since! So if you face such issues, I'd highly recommend getting the multiplus (and any other Victron devices) firmware updated PDQ! (I vaguely remember some months back someone on victron site mentioning that you MUST upgrade multi firmware if you go to full release 3.0 venusOS, and I guess they were right...) cheers V. PS. not using MQTT so not experiencing anything like #225 |
Hello all, today was the 2nd time I experienced something similar. The internet connection failed today while I was in a Teams call, (routing issue at the provider this time)
Power restored and failed multiple times when I was observing my setup, until internet was restored and stopped the cycling. A few weeks ago they cut a Coax cable in our town, and in hindsight the same happened. The I reset the controller to solve the cycling. Since I run the latest Victron firmware the GX now also shows the internal failure notification. I have 14 modules, some rules defined an SD-card (60s logging) and MQTT enabled. Cheers, |
Hi @bertvaneyken thanks for taking the time to report the issue. We've seen this problem on a few installations now, some of it appears to be bugs in the Victron software, but I also agree that DIYBMS MQTT interface appears to add to the problem. The DIYBMS reported to Victron the "internal failure" - this typically only happens when the modules stop responding to the controller. During a power cut, or when the power is going on/off/on/off very quickly, I've seen the symptoms of "power spikes" affecting the DC battery and the modules. Perhaps this could also be seen in your system? |
Hi Stuart, I'm still struggling with this. Looking for a bright idea here after enjoying myself with debugging...
To rule out a hardware issue I ordered a new ESP32 (with external antenna) and some missing chips to build a second controller on a spare v4.2 board. As far as I can see in the code it makes no sense the controller reboots after reporting Low battery over CAN. I just completely disabled the Current & Voltage monitoring as a last attempt. I hope it is something obvious when I replace the controller :) |
The DIYBMS controller should NEVER reboot unintentionally. Can I ask you to provide the initial serial debug output when the ESP32 is power up? I'm wondering if the ESP32 is a particular hardware revision which is causing problems. If you have ordered another one it would be a good test. DIYBMS is reliable - this is a screenshot from my home system, with uptime over 65 days (since I manually rebooted it) and during that time, I've had zero communication issues and over 30 million CANBUS messages. |
No doubt it should be stable and reliable :-) I have never seen CAN errors either. I'm building new modules as well with parts I have laying around (4.40) so I can swap out everything. I did notice the modules do throw some errors (I use the standard baudrate): Logs while running are here, I'll post boot logs tonight. (MQTT was under maintenance in the first part) |
Two observations from the logs... You are getting SD card errors. Might be worth removing it and re-formatting it on a PC.
The available memory is dropping over time - this might be related to the SD card problem, this would ultimately force the controller to reboot if the memory gets too low.
|
I've just removed the SD-card from the controller and I'll leave it running without now. Serial output logs of the initialization are here: (the mqtt password was missing while I ran the dump, so that is why it now fails) |
You were right, it seems that the worn out SD-card is the culprit of the crahes. |
Wow, I always had my suspicion but never any proof the SD card would cause the problem. |
I'm not 100% sure the SD-card only is at fault but it is way more stable without it. I finally could catch a spontanous reboot via de serial output. I (356427567) diybms-mqtt: MQTT counters: Err_Con=0,Err_Trans=1,Conn=1,Disc=1 Core 0 register dump: Backtrace: 0x401b579b:0x3ffd8590 0x401b5880:0x3ffd85e0 ELF file SHA256: 31418cd666101b8d Rebooting... full log: |
Ok, I've had another user report similar problems. |
Definitely a null dereference, I'm suspecting something with the MQTT client or the http server is causing the crash within the event handler but it is not clear which is at fault. |
Thanks for this. You appear to have MQTT enabled, but its not connected to the MQTT server ( |
@bertvaneyken Could you try and re-produce the same test? I managed to get a core panic - @atanisoft does this still look like a null dereference issue?
|
Hi Stuart, I disabled MQTT and it didn't reboot since, however it could run for days or weeks in the past, so no real proof there. Tonight I re-enabled MQTT and did the following tests:
None of this provoked an issue... so i'm not sure what the direct cause would be. |
Describe the bug
If the wifi connection is lost the controller reports to my victron that the battery voltage is low.
Hardware/Software Versions
Controller version (from PCB): 4.5
Host name: DIYBMS-009DAA84
Processor: ESP32
Version: 5b7135f8127c6fd9d5d18525f7d5de72a32b4232
Compiled: 2023-04-17T08:23:56.977Z
Language: en
SDK Version: v4.4.4
Min free Heap: 59820
Free heap: 109184
Heap size: 293796
To Reproduce
Steps to reproduce the behavior:
Break the wifi connection while the controller is running.
The text was updated successfully, but these errors were encountered: