Where is the transmission range sensor/neutral safety switch on a Daewoo Lanos?

I am having problems with my 2002 Daewoo Lanos not cranking or starting randomly. In the past, I have been able to resolve this problem by inserting the key into the interlock slot on the transmission shifter, cycling through all the gears, and back to P or N. However, even that no longer works all the time.

I needed to go to a doctor’s appointment this morning, while it was still somewhat cold, and I could not get the car to start. I ended up driving my truck instead. When I got back, I tried to start the Daewoo, and the same thing happened, but after fiddling with the transmission shifter, it eventually started.

Still, I don’t want to have a car which will not start reliably. Especially because this problem could occur far from home, in a terrible neighborhood, etc.

I am trying to figure out where is the switch or sensor which controls this function. If it is located inside the transmisison itself, then I need to figure out if it is accessible without taking off anything more complicated than the fluid pan.

It’s located on the transmission below where the shift cable attaches to the shaft lever.

Tester