I am using a BS170 FET transistor to turn on/off a magnetic rotation sensor RM08  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.
© Espruino, powered by microcosm.
Report a problem