which code?
The only CMP DTC I see for Ford's OBD in 1998 is P0340, Camshaft Position Sensor Circuit Malfunction. It's generated when the Ignition System Check Operation is run as described below:
The ignition system is checked by monitoring three ignition signals during normal vehicle operation:
Profile Ignition Pickup (CKP, commonly known as PIP), the timing reference signal derived from the crankshaft 36-tooth wheel and processed by the EDIS chip. PIP is a 50% duty cycle, square wave signal that has a rising edge at 10 deg BTDC.
Camshaft IDentification (CMP, commonly known at CID), a signal derived from the camshaft to identify the #1 cylinder
Ignition Diagnostic Monitor (IDM), a signal that indicates that the primary side of the coil has fired. This signal is received as a digital pulse width signal from the EDIS chip. The EDIS chip determines if the current flow to the ignition coil reaches the required current (typically 5.5 Amps for COP, 3.0 to 4.0 Amps for DIS) within a specified time period (typically > 200 microseconds for both COP and DIS). The EDIS chip also outputs status information when the engine is not running. First, the relationship between successive PIP events is evaluated to determine whether the PIP signal is rational. Too large a change in 3 successive PIP indicates a missing or noisy PIP signal (P0320). Next, the CMP edge count is compared to the PIP edge count. If the proper ratio of CMP events to PIP events is not being maintained (for example, 1 CMP edge for every 8 PIP edges for an 8-cylinder engine), it indicates a missing or noisy CMP signal (P0340). Finally, the relationship between IDM edges and PIP edges is evaluated. If there is not an IDM edge (coil firing) for every PIP edge (commanded spark event), the PCM will look for a pattern of failed IDM events to determine which ignition coil has failed. If the ignition coil cannot be identified or if the engine is running and there are no IDM edges, the IDM circuit is malfunctioning (P1351).
If an ignition coil primary circuit failure is detected for a single cylinder or coil pair, the fuel injector to that cylinder or cylinder pair will be shut off for 30 seconds to prevent catalyst damage. Up to two cylinders may be disabled at the same time on 6 and 8 cylinder engines and one cylinder is disabled on 4 cylinder engines. After 30 seconds, the injector is re-enabled. If an ignition coil primary circuit failure is again detected, (about 0.10 seconds), the fuel injector will be shut off again and the process will repeat until the fault is no longer present.
From the above I believe the DTC could be set for either the CMP or one of the ignition coil packs.
It seems unlikely to me that the above described failure would result in high rpm at start up. I think the start up flare is unrelated to your CMP DTC. I suggest you try cleaning your IAC valve to see if that makes a difference.