I have a problem when using LM358 in compare mode.
I'm trying supply LM358 with 5V (V+ = 5V, V- = GND).
The non-inverting input is 0.6V and the inverting input is 0V and 1.2V, respectively. When the inverting input is 0V the output is around 4.2V (this is okay) but when it is 1.2V the output is between 0.75V and 0.9V.
Is there any way to decrease the output to nearly 0V (in the datasheet they said the negative rail is about 100mV when I_out is around 10uA)? Or do I just change to other rail-to-rail opamps?
TRIP_1
is a wire connected to STM32