The CMP sensor (camshaft position sensor) responds to a sprocket on the camshaft. The function of the sensor is to provide the PCM (Powertrain Control Module) with information about the speed and position of the camshaft.
This diagnostic code is set when the PCM detects a high resistance. It is worth mentioning that there are vehicle models that have two Camshaft Position Sensors. But in this case, the DTC code P0343 OBDII refers to sensor A.