# What is the safest way to trigger an output?

I need to trip a 12V output with a signal. In other words, I will send a signal through the output of my microcontroller and this signal will activate its output.

I've figured out several ways to do this, the most common ones being activation with relay or activation with Mosfet. As in the examples below.

My concern is reliability, I need to make sure that the output is triggered. How many drives per day will be needed to ensure that the system supports a large number of activations?

How can I know which of the forms of activation is the most reliable? Which one will guarantee the activation of the output without fail and which supports the largest number of activations?

EDIT- The load connected to "output12v" is an electronic lock that consumes around 1A.

simulate this circuit – Schematic created using CircuitLab

simulate this circuit

• Define safe. Electrical safety? Functional safety of a control system? Neither of the circuits here are monitored so neither is "safe" from a functional safety point of view. You can use neither to control a safety-classed function. In addition, relays are notorious from breaking after a certain number of operations. – Lundin Apr 10 at 12:58
• @Lundin Security in the sense of guarantee. If the signal is high, I need to guarantee 12V at the output. – Eduardo Cardoso Apr 10 at 13:04
• There are no guarantees. You need to decide how reliable is reliable enough. Does it have to work correctly 99.9% of the time? or 99.999% of the time? There are many single points of failure in both of your proposed designs. You need to do a fault tree analysis to determine the probability of system failure based on individual failures and their probabilities. You may need to add redundancy. Also, how reliable is the firmware driving this control signal? How reliable is the lock itself? – Dave Tweed Apr 10 at 13:11
• Well, you can't know that, since you don't monitor the output. – Lundin Apr 10 at 13:12

## 3 Answers

Either circuit has failure modes and you'd have to analyze possible abuses such as transients on the 12V line and possible shorts on the output to have some hope of deciding between them.

Relays are more rugged but have a limited and fairly predictable life. MOSFETs can fail at any time, but in a benign environment, and if minimally stressed (lots of margin on voltage ratings, minimal temperature cycling from self-heating etc.), have few wear-out modes.

Relays tend to fail 'off' when they wear out (but they can stick) and MOSFETs tend to fail 'on' (but not always).

If the consequence of failure is an unsafe condition for people or significant property damage, you should not use either circuit alone. Either add redundancy or acceptably mitigate the damage with other means such as fully independent limit controllers etc., preferably using a different physical mechanism to operate. For example, I have a molding machine. The consequence of the platen closing unexpectedly could be a crushed operator. There are three interlocks- one electrical, one hydraulic and one a mechanical rod that physically blocks the clamping action.

Relays are good for galvanic isolation. But if you don't need to isolate switched voltage from voltage that powers your microcontroller, then I thing the more suitable is solution with MOSFET.
Relays are electro-mechanical components, so thay could break after less switchings than MOSFETs.
Also, you can easily find MOSFET that can hold 1 A.

I am in the MOSFET camp. If you want high reliability you can parallel two MOSFETs and drive them with separate signals -- one as the primary switch, and one as the backup. I would also suggest a PGOOD (power good) type signal as feedback to the MCU that the +12 V has indeed been supplied.

simulate this circuit – Schematic created using CircuitLab

• This is overly simplistic, and still has many single points of failure. For example, "failure to turn off" is also a kind of failure, and you've done nothing to address that. Adding a monitor does not make a system more reliable; it just provides an indication that a failure has occurred. Not the same thing. – Dave Tweed Apr 10 at 13:53
• @DaveTweed From the OP: 'I need to make sure that the output is triggered.' And, 'Which one will guarantee the activation of the output without fail and which supports the largest number of activations?' Sounds like failure to turn off is not a concern. – calcium3000 Apr 10 at 14:08