It's best to consult a repair manual specific to your 1997 Ford F-150 4.2L engine for a precise diagram and location. A visual inspection with the engine bay clean will also help you locate it. Look for a small sensor with a single wire connected near the oil filter and the general area described above.