ESP32 behaving unexpectedly, not sure how to diagnose

usinjin
Posts: 5
Joined: Wed Aug 30, 2017 6:13 am

ESP32 behaving unexpectedly, not sure how to diagnose

Postby usinjin » Fri Feb 09, 2018 3:33 am

I'm using an ESP-WROOM-32 with ESP-IDF. We're getting several sensor's data over I2C and outputting to a servo motor. We're also using BLE in our project. Sometimes, when we boot, or ESP32 seems to go a bit crazy and ignore the code. It's supposed to wait and let a BLE connection initiate and then wait for commands from a mobile application. Very often it's fine, but other times it turns the servo motor at full power and garbage comes over the serial connection, and the whole system is completely unresponsive, forcing us to kill the power to it. After resetting it, it goes back to normal and runs fine. I'm not sure where to start looking for the issue, because when the system goes a bit crazy, nothing intelligible comes over serial that could help us debug. Where can I start to look for why this is happening?

mistergreen
Posts: 10
Joined: Tue Jan 23, 2018 4:56 pm

Re: ESP32 behaving unexpectedly, not sure how to diagnose

Postby mistergreen » Fri Feb 09, 2018 2:37 pm

Did you protect the ESP from the motor with diodes & capacitors?
Motors will produce current when moving. I'm guessing that the garbage you see is the extra current. I assume the ESP would crash and become unresponsive.

usinjin
Posts: 5
Joined: Wed Aug 30, 2017 6:13 am

Re: ESP32 behaving unexpectedly, not sure how to diagnose

Postby usinjin » Sun Feb 11, 2018 3:42 am

mistergreen wrote:Did you protect the ESP from the motor with diodes & capacitors?
Motors will produce current when moving. I'm guessing that the garbage you see is the extra current. I assume the ESP would crash and become unresponsive.
Thanks for the reply. We have a 15v 1400uF cap on the servo 5v line, but no diodes, I will add one and see of that fixes our issue.

Who is online

Users browsing this forum: No registered users and 8 guests