But when adding a digitalWrite (for steering my relays) in the function that was called by the timer, the ESP32 rebooted when coming in this part of the code. When i removed the digitalWrite, all works fine.
Does anybody know why this happens and how it can be solved?
Add details :
• Hardware model + communication type. For example: Arduino UNO with Ethernet Shield
• Smartphone OS (iOS or Android) + version
• Blynk server or local server
• Blynk Library version
• Add your sketch code. Code should be formatted as example below.
Simply paste your code between ``` If you don’t format your code, your topic can be deleted by moderators.
Hi John,
i’m using Blynk legacy.
I indicated the added code by /added code/ . Without the added code if works fine, with the added code, the device reboots/stalls when triggering the rollerup-button.
John, Blynk_Coeur, thanks for your advice. Meanwhile i found the problem: power loss of the ESP32 due to triggering of the relay. Blynk_Coeur you were spot on. I was confused because i hadn’t any issues directly in the button routine, but the timespan for the relay was much shorter (1 ms vs 10ms) there.