I'm constructing an H-Bridge to control a linear actuator. I've done so by using a 2-channel relay module, some buttons, and a ESP32. I do not believe this is an issue of debouncing as I account for this scenario in software to ignore anything that occurs in under 800ms (this is long I know will change later, only for testing due to this problem)

However, after taking a look at one of the inputs with my oscilloscope, I notice that the inputs are experiencing a lot of noise with the actuator connected and in motion. Could someone explain why this is occurring? Is it related to the back EMF in any way? I wasn't sure if that would appear on the 3.3V rail of the ESP32 where the buttons are through the relays.

The ESP32 is currently powered through a USB port on my computer, and the linear actuator is powered through a standard 12V wall adapter. The input pins for the buttons are configured as pulldowns since they are normally open contacts. In my interrupt routine I look for a positive edge for triggering the actuator. I wonder what would happen if I were to trigger on a high signal rather than a positive edge.

So far, I've tried adding a 10uF and smaller ceramic cap to the 3v3 rail with no change.

Maybe a high frequency filter on the 3v3 rail would be beneficial?

I also have never looked into Schmitt triggers, I assumed that was more related to button debouncing which is not the problem here.

Here is a screen capture from my oscilloscope when the ESP32 false triggers and switches directions of the linear actuator without physically touching another button:

enter image description here

For reference, this is the relay module I used:

  • \$\begingroup\$ This noise looks exactly like noise from a poorly designed DCDC converter. \$\endgroup\$ – Stefan Wyss Nov 25 '18 at 8:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.