chuckdubs
Posts: 5
Joined: Wed Aug 15, 2018 4:10 pm

AC compressor feedback causing undesirable effect in RPi

Thu Aug 23, 2018 11:27 pm

I have an RPi 3 B+ hooked up to a 4 channel sainsmart 5v relay, and the relays are hooked up to three 24v DC solenoid valves and one AC 115v compressor.

The relays have their own power supply so they are isolated by the board, and the 24v circuit has a separate power supply.

The AC motor causes some kind of feedback or noise when the relay is switching it on or off which is causing undesirable effects, like buttons and the relay double firing and false signals going to the RPi.

I know that when I had this same / similar issue with the DC solenoids, adding a flyback diode at the solenoid mitigated the problem. Tried that with the AC motor and the diode exploded (learned that you can't use those diodes with AC ).

Is there something I can put in the AC circuit to prevent the feedback similar to a diode in a DC circuit? Also, I would prefer to do it at or near the relays or RPi rather than near the motor if possible.

User avatar
davidcoton
Posts: 5083
Joined: Mon Sep 01, 2014 2:37 pm
Location: Cambridge, UK
Contact: Website

Re: AC compressor feedback causing undesirable effect in RPi

Fri Aug 24, 2018 8:59 am

chuckdubs wrote:
Thu Aug 23, 2018 11:27 pm
Also, I would prefer to do it at or near the relays or RPi rather than near the motor if possible.
That is almost certainly a wrong approach. The motor feedback is coming back down the wired to the Pi. It needs to be removed as near the source (motor) as possible.

My approach would be:
Get an extra relay, 24V DC coil and 120V AC contacts.
Mount it in a suitable box (waterproof and fingerproof) as close to the compressor as possible.
Connect all the mains there, nowhere near the Pi.
Let your Sainsmart board switch the 24V via a new cable to the new relay.
You can and probably should use a diode across the coil of the new relay.
Check all wiring, test and commission.
Job done.
Signature retired

Return to “Troubleshooting”