openevse_esp32_firmware
openevse_esp32_firmware copied to clipboard
bug/crash with scheduler api
I'm in holiday I can't track it but seems I saw a bug if only one schedule is set ( for example a "disabled" schedule with id: 1 , without an "enabled" one )
Can't see if it's a crash or bug from here, but then common status data from create_rapi_json are not published on MQTT, I think it's the same with http, event_send is not called. Either it crashes before or something else.
I did have an issue with something similar, thought I fixed it, will have a look.
I see some events.getnext() in scheduler.cpp without checking if there's such next event first, could this be the culprit ?
While working on the Timers part of the new GUI, I get this issue as the UX I'm doing is creating each timer separated.
I confirm the OpenEvse-wifi crash if there's only one timer. Module crash in the wollowing 30 secs.
It doesn't happend if there's more, whatever the enable/disable parity is respected or not.
@jeremypoulter , do you have any hints on this issue yet ? I have no debugger here, and no access to the esp32 in production to fix that on my side.
Sorry, I have not had a chance to look at it yet
@jeremypoulter Just a hint as I'm looking at it, it's not the fact that we have only one timer, it seems to need booth an active and disabled timer. I've tried with 2 enabled or disabled timers, and it also crash the firmware. But I still don't know where it segfault, I need a stacktrace