Switching a 9v load
Switching a 9v load
I want to use the esp32 to in place of a physical switch on a bms. It shows a 9v and 5mA on the line. Can I use a GPIO pin pulled set low, to ground the current and activate the bms without damaging the esp32? I know i could use a load driver or ssr or nfet with some resistors as an alternative.
-
- Posts: 9757
- Joined: Thu Nov 26, 2015 4:08 am
Re: Switching a 9v load
No, you cannot, the ESP32 pins are not specced for a 9V voltage. Suggest you use a GPIO to drive a mosfet that lowers that line instead.
Re: Switching a 9v load
You will need a transistor or some other switching device.
If the current, etc, is low enough, just a small n-channel mosfet with low enough threshold voltage, switch the low side of the load and it should work with a gpio pin on the gate. Obviously put a resistor to protect the esp32 gpio pin (probably 1k would do), if you are worried about electrical noise accidentally activating the load during startup (or any other time the esp isn't driving the pin, for example, sleep), then add a pull-down resistor to make sure it's off by default.
If the current, etc, is low enough, just a small n-channel mosfet with low enough threshold voltage, switch the low side of the load and it should work with a gpio pin on the gate. Obviously put a resistor to protect the esp32 gpio pin (probably 1k would do), if you are worried about electrical noise accidentally activating the load during startup (or any other time the esp isn't driving the pin, for example, sleep), then add a pull-down resistor to make sure it's off by default.
Who is online
Users browsing this forum: Bing [Bot] and 185 guests