I have a 98 Mazda 626 GF 2L ATX which I don't drive allot, and which has had a few unusual stalls and almost stalls, one of which I had trouble restarting after.
In the past say two months, I had incidents where an alert light on the dash would come on ( a picture of a car with a big key superimposed over it ), the engine would almost stall ( as if electric power was cut ), it would recover and the light would go off. This would all happen in around a second.
Then today, the car died while I was idling. It was similar to the previous "almost stalls" in that there was no sputtering or shaking; it was as if someone had simply unplugged the battery, a very gentle, quite stall. However, that "car & key" picture did not come on. At first I was unable to restart the car. I tried a few times over the course of a few minutes with no success. So I waited maybe fifteen minutes, came back and it started right up. I drove home, turned it off, started it up again and was sitting letting it idle for a few minutes when the same thing happened again. However this time it started right up.
I hooked up my laptop with the ForScan software and pulled a P1500 DTC:
DTC 1500 indicates that the VSS input signal was intermittent [Possible Cause] • Damaged VSS • Damaged ECM (PCM) • Intermittent VSS connections • Intermittent open in VSS harness circuit(s) • Intermittent short in VSS harness circuit(s)
I cleared the code, restarted the car a few times, did some slow drives around the parking lot to collect some test data, and so far it didn't stall again and the code didn't come back. I asked a separate question regarding the test data I gathered. I also ran the KOEO and KOER self tests which both passed with no errors.
Some things which might ( or might not ) be related are that I recently had to replace a bad Turbine Speed Sensor, and a verifiably bad alternator, and my remote entry key stopped working. I also had to replace the Lambda sensor a while back. I'm a bit worried maybe that bad alternator was slowly frying my electrical components. There is also an aftermarket keypad immobilizer which was disabled because it was causing problems, however the components like the relay for disabling the fuel pump, are still in place. I'm also having a problem with rough idle under load, when I turn on the A/C, electrical loads, or hold down the brake with the car in drive. That's everything I can think of at the moment.
Anyways, I'm at a bit of a loss as how to proceed. I recently went on a fairly long drive ( three hours round trip ) with no incidents, but now I'm a bit worried about driving the car around.
What should I do now?
EDIT Sept. 3rd 2016
So I tried to follow the procedure in the video that @Zaid posted. I hooked up my computer, let the car idle, and went around shaking and wiggling the wiring harness and the wiring of every individual sensor I thought might be relevant, without any visible results. I also went under the drivers side dash and started wiggling wires, and went to the passenger side and wiggled around the connector to the ECU. I probably let it idle 30 minutes, and then I drove it around the neighborhood for about ten minutes on very bumpy roads, but couldn't reproduce the problem.
I want to take the family on a 2 1/2 hour trip tomorrow, but am a little nervous and not sure how to proceed at this point.