I put too a check_status when a publish to a topic in every 500ms.
Now esp32 is online about some last 3 hours:
Here is the code:
Code: Select all
while True:
c.check_msg()
check_status(c)
gc.collect()
sleep_ms(500)
Code: Select all
while True:
c.check_msg()
check_status(c)
gc.collect()
sleep_ms(500)