If you have a code P0024 it actually means the sensor is working and it detects that the camshaft is in a position that the ECM doesn't expect it to be at that time. Attached are the items that can cause that code to set on your engine.
A very common cause for this code is low or dirty oil as it causes the oil control valve to the phase control to stick or bind and the camshaft phaser doesn't move properly and you get this code. I would probably do an oil change if it's been more than 3-4000 since the last one, clear the code and see if it returns.
It can also be caused if the oil control valve has an issue where it isn't applying the correct pressure when selected, that can be caused by a piece of dirt or sludge blocking the screens on it or a faulty valve. Testing it is easy if you have a test meter. You unplug the oil control valve for that cam and test it for it's resistance. You want between 9.4 and 10.4 ohms of resistance if the valve is good. This won't tell you if it's plugged though, for that you need to remove it and see if there is a problem.
As for the oil on the sensor, yes that is normal because it is inside the engine next to the timing gears.
Images (Click to make bigger)
Monday, March 2nd, 2020 AT 12:48 PM