I can't quite get it to work.
I used the LM393 as comparator.
The inverting input is collector-3V (with a diode drop).
The noninverting input the emitter voltage.
Output of comparator with a pullup to the 10v low tap.
Because the comparator has such a high imput impedance, a parallel resistor is required, to have a diode drop.
If the comparator switches to on, the voltage goes on only 3V higher than in the off state (100R pull up), which turns the fet not complete on.
Lower pullups make the circuit oscillate.
Maybe it is obvious but all the different voltages which different reference to each other confuse me

Edit:
I tried an different circuit with an optocoupler, but even here I could not get over 3V Gate-Source Voltage.
If i disconnect the gate it goes up to 10V

Edit2:
I got it working
