Voltage drop in latching circuit, cant figure out why.

Add a 10k from D7 to GND.

Home work: