So this project I'm working on, Has a Mosfet gate that's controlled through a high side switch and an attiny. The thing wrong is, The MOSFET turns on when i connect the batteries to the circuit, But turns off after a short while.
Things I've done:
- Thought it was a voltage issue, But the charge pump shows a constant 13V output.
- Thought it was a MOSFET issue, took it out, tested it, It's working perfectly.
- Thought it was a microcontroller issue, so connected an led with the pin driving the high side switch, it lights up perfectly.
I can't figure how to measure gate voltage, because every time i connect the multimeter probes to the gate and some ground, the gate charges up and turns on. The interesting thing is it almost feels like a capacitor, ( which MOSFETs basically are ) , when it turns off after a while, I can disconnect the battery and reconnect it and the mosfet turns back on for a short while, almost proportional to the time i kept it disconnected.
least of my problem, the battery display shows 0% just as soon the relay turns on, even when theres no short or even a minute voltage drop across the batteries,it could be that the module is faulty. But i have a much much bigger problem above.
heres my circuit.
One more thing ive forgot to mention, theres some sort of leakage when i have the attiny disconnected, a very faint amount of current flows throw the converters and turns on the onboard led of the buck converter with a really low brightness.