I thought I could use two BS170 transistors working as switches in series, to create logical AND functionality. My circuit is switching an LED with 1.5V of forward voltage and 10mA current set by a resistor. The positive voltage is supplied by an LM7812 regulator and not the battery as the diagram shows.
A problem I didn't expect is that when only the left switch is closed, the circuit is conducting enough current through the LED to activate a transoptor of which this LED is a part. This problem is not present on the simulation as shown in the picture. The simulation behaves as I would imagine.
I didn't spend too much time on this when making a quick prototype, but IIRC on the right transistor, I could measure 0.3V of drop between drain and gate and 2.33V between gate and GND. This made me think that it conducts the current of the LED, but why?
I solved it ultimately by using NPN transistors in the same configuration, but initially I wanted to save some base current by using MOSFETs. Now I would like to know the reason why the initial solution behaved this way.