Instead of reading 2 ADCs and comparing them to see which one is greater, im going to use this. Now i can simply use 1 digital pin on my microcontroller and preform less computations to run my custom digital boost converter.
I plan on running it around 20kHz-200kHz so this should work with some 2n3904 and 2n3906 BJTs. If you plan on using this too, make sure you put a capacitor on the input. The current spikes during the output transition because its charging the small internal capatance in the BJTs as fast as possible. Obviously you cant reduce the capacitance in a BJT, so just reduce the resistance until it can switch the output fast enough. Note that you can only compare values between ~0.7v and ~4.3v. Increase the supply voltage or use a voltage divider to address this problem.
If you try and use this like an opamp and buffer or amplify an input, you will fry this circuit. It is not designed as an opamp. However, you can use it like an opamp if you expect the output to be either Vmax or Vmin.