hey scotty i have a Hyundai Accent 2000 with about 250k miles and code p0342 (camshaft position sensor A circuit low input B1) i replaced the sensor but the same code stil shows up.
You may need a new timing belt/chain.
If the sensor has been replaced, then it is reading correctly but the belt/chain is either too advanced/retarded. This happens with age as they loosen and begin to slip.
It won't be a cheap repair, particularly if you have a chain.
That was actually the first thing I replaced when I got this car
Did you replace the sensor with an OEM one? See here for what else it could be:
https://www.obd-codes.com/p0342
Also, see below at post #10
Those have timing belts and its most likely the timing belt that's going out and u will need a new one. They are also interference engines, so make sure you replace it on time before the valves meet the pistons.