MOSFET circuit, pull-down resistor not pulling down

Discussion in 'General Electronics Chat' started by Nicholas, Jun 13, 2016.

  1. Nicholas

    Thread Starter AAC Fanatic!

    Mar 24, 2005
    Hi guys

    I have my circuit that has a micro controller connected to the MOSFET circuit below. It is driving a coil at
    something like 30-40V. Now, when I turn on the controller, it has 4.9V on the output pin right away, energizing
    the coil right away.

    I just want to be confirmed, this is a problem with the controller, not the circuit, right? My software sets all pins to
    off, but that would take time in the real world...leaving the coil on until the device has booted and started the software,
    thus turning the pins off (and coil off)

    Any advice?


  2. nigelwright7557

    AAC Fanatic!

    May 10, 2008
    Sounds like a problem with the microcontroller.
    On power up its outputs should be tri state.
    Its not until you setup the port does it become input or output.
    Set the port low first then set the direction of the port.
  3. dannyf

    Well-Known Member

    Sep 13, 2015
    It may not even be a problem with either the mcu or the circuit. Not enough information.
  4. AlbertHall

    AAC Fanatic!

    Jun 4, 2014
    Which microcontroller, which pin?
  5. Roderick Young


    Feb 22, 2015
    The circuit looks good. If you were using a PIC, this would be perfect, as the processor powers up with IO pins floating by default. If you're seeing the coil energized at power-up, make sure you have the right connections on your n-channel MOSFET, the IRL540. Looking from the top, the pins go left to right, Gate, Drain, Source.
    JWHassler likes this.
  6. Dodgydave

    AAC Fanatic!

    Jun 22, 2012
    Are you sure its the micro thats booting up with the output high, what happens if you short the G/S terminals on the fet and then power up, does the relay operate then?

    As before, which micro is it?