Can a MOSFET get this pin to float?

I’m designing a lipo battery charger that uses an MCP73831. An MCU needs to be able to stop/start the charging as well, and according to the MCP73831 datasheet, leaving the PROG pin to float would disable the chip.

Would an N-MOSFET be able to “disconnect” the pin sufficiently to let it float when it’s off? The connection is:

PROG --------------Resistor ------------- N-MOSFET (gate controlled by GPIO) ------------- GND

Hi @aonsquared, have you considered connecting PROG directly to your gpio via the appropriate resistor? For normal operation, set the gpio as output and pull it low. Then you can set it as an input and the effect would be as if the PROG was floating, if your gpio was of sufficient resistance in input mode. Datasheet should provide the input resistance. You may need to disconnect the gpio from VSS / GND or pull it up to VCC. Although this looks like it should work, depending on your microcontroller, it’s definitely worth bread boarding to confirm the behaviour is as desired.

1 Like

Thanks for that suggestion, I haven’t considered that yet! If the GPIO can sink whatever current it is to ground then that might be the way to go.

Okay answering my own question here, it’s in the datasheet…

PROG Input
Charge Impedance Range: 2 — 20 kΩ
Minimum Shutdown Impedance: 70 — 200 kΩ

So as long as the off impedance of the mosfet is more than that, it should work…

You connect the PROG pin to ground through a resistor (Rprog) if you want to program the charging current, and either let the pin float or tie it to Vcc (or any logic HIGH voltage to disable the charge current control. If you want to use an Arduino Uno (or other ATMega328-based board) the resistance to ground is effectively about 26 ohms, so you could use a resistor of value (Rprog - 26) between the GPIO pin and the PROG pin. You’d drive the pin LOW to program the charge current, and drive the GPIO pin HIGH to disable charge current control.