Electrical – Two issues, re: driving relay with logic levels

arduinorelayttl

Hey people I'm driving a relay with a arduino-teensy with 3.2v logic levels.

Some background. I'm going with a mosfet because the coil voltage is relatively high. The relay will have 20a/220v contact voltages. I'd like to have an LED turn on when the relay is active, and I'd like to have a manual switch to override the logic control of the circuit.

Two questions.
1) could someone verify that this is the best way to light up the LED? I read on line the parallel circuit is better than running the LED in series, if it fails then the relay fails.

2) Which choice would be best to use a circuit to override the logic level coming from my arduino? If the arduino pin mode is:
pinMode(relayPIN, INPUT);
does it care if I put 3.2v external on that thing? Or would it be better to just connect the drain side of the mofset (Q2) to ground?

thanks much.

circuit diagram for relay driver

Best Answer

1) could someone verify that this is the best way to light up the LED? I read on line the parallel circuit is better than running the LED in series, if it fails then the relay fails.

It depends on details. How much current does that relay need (you did not specify the type nor parameters)? If it is higher than LED can handle then you cannot put the LED in series. Another downside is that LED in series will decrease voltage across relay coil.
I think it is much better to put in parallel, exactly as you have it. If LED fails it usually fails as dead short circuit, and relay will trigger even without LED is lit up (because it will be short). So if you would put the LED in series it will not help you at all.

2) Which choice would be best to use a circuit to override the logic level coming from my arduino? If the arduino pin mode is: pinMode(relayPIN, INPUT); does it care if I put 3.2v external on that thing? Or would it be better to just connect the drain side of the mofset (Q2) to ground?

It depends of what type of button you will use. If it is suitable for 24V and level of current that relay coil needs than IMHO it's better to override that MOSFET (that is in the second schematics).

If you would use the first one, you should put some 10k resistor on arduino pin output and it should be fine. It would prevent short circuit from your manual switch to arduino pin.