Multiple signals controlling relay

  • Thread starter Thread starter solvejskovlund
  • Start date Start date
AI Thread Summary
The discussion centers on controlling a relay through multiple signals, including a forced OFF signal from a microcontroller (MC), a release signal, and a manual ON/OFF switch. The relay must maintain its "force OFF" state even during power outages, requiring a solution that can remember this state. Suggestions include using a latching relay for safety and considering non-volatile memory to ensure reliable state retention. The complexity of the design raises concerns about safety, emphasizing the need for fail-safe mechanisms and minimal software functionality to prevent dangerous scenarios. Overall, the conversation highlights the challenges of integrating these control signals while ensuring safety and reliability.
solvejskovlund
Messages
58
Reaction score
2
I'm need to control a relay in three ways:
1: Forced OFF signal. This is a signal triggered from a MC that I have no access to change. It is a 1 wire output that is normally floating, and pulled to ground for exactly 1 minute when the MC has detected that the relay should turn off. Important thing here is that the relay does not come back to ON when the MC stops pulling the signal low (would have been a lot easier if the MC kept the wire pulled to ground as long as the forced OFF situation was valid.)

2: Release forced OFF signal. This is a 1 wire output from the MC that is normally floating, and pulled to ground for 1 minute when the MC decides it is ok to turn the relay on

3: manual ON/OFF signal by push button or an on / off switch. When this switch is pressed / switched OFF, the relay should go OFF. When this button is pressed / switched to ON, the relay should turn ON if the last signal from the MC was 2 (release). The button should be ignored if the last signal from the MC was 1 (force OFF). If manual switch is in ON position when signal 2 (release) is sent from MC, the device should NOT switch ON. Only the manual ON signal should turn the relay ON.

And to make this even more complicated, this device has to remember "force off" through a power outage. (It will no receive new signals during power outage.)

So, this control unit basically has 4 states:
"Force OFF" (triggered by 1. Must be remembered through power outage)
"ok to turn on" (triggered by 2 or OFF by manual switch)
"ON" (triggered by manual switch)

Does such a device exist? If so, what would be the proper search terms to find it?

I'm thinking one way to approach this could be to connect devices in series like this:
power positive -> relay coil -> manual ON/OFF switch -> device that decodes MC signal -> GND
With such a connection scheme, the device could be simplified to have signal 1 to turn ON, signal 2 to turn OFF. The manual switch in this case would have to be like those used on power tools that ensures that the tool does not restart after power outage.

Any better options?
 
Engineering news on Phys.org
Use an N-chan MOSFET to drive the relay, controlled by the MC, with pull down on gate.
Can you program the MC to remember the "force off" in eeprom?

Or must this be a separate electronic logic block, with a battery backed up CMOS RS flip flop?
 
solvejskovlund said:
And to make this even more complicated, this device has to remember "force off" through a power outage.
That suggests using a latching relay.
 
  • Like
Likes Averagesupernova and DaveE
This sounds like a safety critical application. If so, I like the latching relay idea.

You need one non-volatile memory bit that can be set quickly and reliably as the power dies. Proving that your uP, POR, watchdog, etc. can do this and have it be guaranteed in synch with the relay HW, then power up in the correct state will be a tough sell to a safety inspector. There's a lot of stuff between an eeprom and the actual relay that can go wrong. It's also a lot harder for some EE down the road to screw it up by changing parts, wires or PCB layouts than to make a mistake typing new code.

Our design rule with for similar equipment was that there should be nothing the SW can do to make it dangerous. Like physically impossible. In a case like this the uP probably has to be involved, but it should be done carefully in a fail-safe manner; simple minimal functionality.
 
  • Like
Likes Averagesupernova and berkeman
Sorry for the late reply - I lost my phone - only way of internet access.I don't have any access to make changes to the MC behavior. Hence everything has to be a separate logic block.I'm also thinking of dropping the MC signal. The MC makes its decision based on voltage from a sensor. It would probably be easier for me to just sense the voltage from that sensor. That would also eliminate the need for remembering state after power outage - just sense the voltage again.

The trigger (force off) signal seems to come when sensor voltage is 2.54v, and the release signal comes at 2.76v. In the event of power outage it just needs to startup in the OFF state. This approach simplifies the circuit into a voltage sensing relay trigger. I just need to be able to fine tune the triggers to match the MC trigger levels.
 
solvejskovlund said:
Any better options?
I am not quite sure of the logic for the case "When this button is pressed / switched to ON, the relay should turn ON if the last signal from the MC was 2 (release). The button should be ignored if the last signal from the MC was 1 (force OFF)". Please clarify the words release and force OFF. I thought condition 2 was ON.
 
Suggested circuit:-
relay (2).webp
 
As I mentioned, I am not too sure of the logic required for the MC ON setting and the manual ON setting, but can al;ster this as required.
 
Back
Top