I dont work much with mosfets so I dont really know how to go about this.
So pretty much I have the circuit above, What's happening is that the Source of the mosfet is outputing around 3.3V and not close to 5V. I understand there will be resistance as RDS(on) however its 0.200ohms. Shouldn't make it 3.3V.
So I tried this configuration, what happens now is that:
I am still not getting ~5V at the Drain
The mosfet gets real hot
Now the gate voltage is not even 5V, but once I take out the mosfet, 5V returns back at the output of the comparator.