Internal pull-down enough for FET?

Posted on
  • Hi!
    I am using a BS170 FET transistor[1] to turn on/off a magnetic rotation sensor RM08 [2] that draws ~30mA. The transistor is placed between sensor ground and GND and the gate pin is connected to D15. The whole thing is powered with a 3.7v lithium battery.

    Initially I used a 100kohm resistor between my control pin and GND, but it seems like it works as well without (using the internal I presume). I just do digital write 0 or 1 on the control pin. My question is if this is a legit way to do it or if I should expect any problems? Not using the external resistor makes the assembly much easier in my application.

    [1] https://www.electrokit.com/uploads/produ­ctfile/40320/40320170.pdf
    [2] https://www.rls.si/eng/rm08-super-small-­non-contact-rotary-encoder

  • My question is if this is a legit way to do it or if I should expect any problems?

    No, that sounds fine. A FET shouldn't really need a resistor - just make sure that at boot time you digitalWrite(0) to stop it floating, which could leave the sensor on/off.

    Only thing I would add - are you powering the sensor from 3.3v, or from the LiPo? Because if it's from the LiPo you could hit problems - when the FET is off, the sensor will then be sitting at 3.7v (including the IO lines) which will be putting stress on the microcontroller. No problem if you're powering from 3.3v though

  • Thanks for quick answer! Yes I power the sensor from 3.3v. Thanks for pointing that out.

  • Post a reply
    • Bold
    • Italics
    • Link
    • Image
    • List
    • Quote
    • code
    • Preview
About

Internal pull-down enough for FET?

Posted by Avatar for user137267 @user137267

Actions