Most modern car engines use a crankshaft sensor to monitor the engines crankshaft rotation. This sensor sends feedback information to the cars computer which then adjusts the ignition and fuel injector timing as engine demands change. When one of these sensors fails it can cause engine misfires, stalling while driving and stalling at idle.
The most common failure for one of these sensors is when the engine is idling it will just stall. This is because the pulse width is at its widest gap because of the slower engine speed. Heat will also cause the sensor to fail because of the thin wire winding which will expand with heat and short out to one another changing the sensors resistance which will cause the sensor to stop giving a signal to the main computer. Once this happens the pulse generation to the injector and ignition systems will stop the engine from running.
Because a crankshaft position sensor is related to engine speed when they fail it may not trigger a CEL light. This is because there are some things that can stop the crankshaft position sensor's signal that will have nothing to do with the sensor going bad such as running out of gas or stalling the engine when letting the clutch pedal out to quickly.
A failing crankshaft sensor is famous for working when the engine is cold and then to stop working when the engine heats up. When you let the engine cool off the sensor will start working again. Testing this sensor's intermittent failure can be difficult due to its ability to start working again. Though you can test the sensors resistance using a voltmeter the true way to test the sensor is to use an oscilloscope when the sensor is hot this is the only true way to test if the crankshaft sensor needs replacement.