microcontroller driving a relay with transistor and Opto-isolator


Posted on Feb 7, 2014

Controlling a relay with stm32 micro controller. For the isolation I have used a 4N33 opto-isolator. As my relay coil needs around 250 mA, I used a mps222 transistor. I figured that the logic gets inverted when I used the gpio as the source voltage for the opto-isolator led. I just used a pull up instead and connected the other end of the led part to the gpio. Gpio is open drain, I will drain around 3mA


microcontroller driving a relay with transistor and Opto-isolator
Click here to download the full size of the above Circuit.

in the pin. I do not have the R2 resistor grounded at this moment. My problem is if in case my stm gets disconnected then my relay will be turned on - which I want to avoid. Could anyone please tell me if adding this R2 will fix the issue




Leave Comment

characters left:

Related Circuits

  • New Circuits

    .

     


    Popular Circuits

    Audio 10 LED VU meter
    Battery-Saving Disconnect Switch
    50 watt power MOSFET amplifier circuit diagram
    Arduino-Board
    OV7670 configuration
    LMD18200 motor controller electronic project
    Audi A6
    mini logger circuit
    Muscular Bio-Stimulator
    ADJUSTABLE SIREN
    IN8510 and power motor driver circuit composed of DAC7520
    Application circuit biaxial magnetic field sensor



    Top