Possibly Cam Timing Fault. The ECU compares the signals from the crankshaft and camshaft sensors and if it finds a discrepancy will log a cam sensor OR cam sensor related fault code and set a low rev limit. On some systems you can clear the codes with the engine running and the car will run OK until switched off , this usually indicates a crank/cam signal error.