This became an interesting job as it progressed.
The vehicle:
2005 Hyundai Terracan 2.9l diesel, J3 engine.
The back story is as follows; The driver had noticed the vehicle appeared to be struggling, whilst pulling his caravan. He pulled off the road and stopped the car. After a period of rest, he tried to start the car and found it refused. It would crank, but wouldn’t fire.
The vehicle was recovered to the garage. The garage ran a code scan and retrieved P0341 camshaft sensor signal malfunction.
They replaced the camshaft sensor, followed by the crankshaft sensor. It still refused to start.
They called me to come and take a look.
I confirmed the repeating P0341 code and so set up the scope. I wanted to confirm the cam sensor and crank sensor operation.

As you can see, this confirmed the operation of both sensors, but the injector was not being switched on, except for the initial event, which is normal for a cam crank sync anomaly.

The close up view, allows me to measure the relationship between the cam and crank signals, for reference.
Unfortunately, I was unable to find a known good reference. This meant I needed to verify the original fault, and so I tested the operation of the original camshaft sensor, to make sure it was not at fault. I connected the sensor to the vehicle and tested it by passing a screwdriver next to the sensor. This resulted in the sensor switching as normal.
With this information, I advised the garage to physically check the valve timing. This was based on the fact, that the sensors all appeared to work and the symptoms would fit with a loss of power and failure to start after stop. It could be a timing belt issue.
The garage informed me the valve timing was correct and so I asked them to fit the original sensors back, so that I could test it as original.
I set up the scope, including a cylinder pressure analysis.

As you can see; there is a problem. The camshaft sensor is not operating.
I then removed the cam sensor to replicate the test I had performed earlier. The sensor did not work! How can that be? The cylinder pressure profile looked okay, but as I had no reference for that, I couldn’t be sure of it. I took it, just in case it showed an obvious fault.
So now I’m faced with the original sensor is faulty and so why was it not fixed by the replacement?
It turns out, the sensor was supplied by the owner, as the garage couldn’t get one from their normal aftermarket suppliers and a genuine one would take some time to be delivered, or maybe it was a cost thing! I’m not sure. I advised they get a genuine sensor and fit it.

As you can see from the above image, the engine now starts a runs. Take a closer look at the cam sensor signal relationship with the crankshaft signal.

You can see how the cam signal position is very different from the previous sensor. I’ve coupled them together to see a little more clearly.

The camshaft sensor switches in completely the wrong place, I don’t even know how that can happen. But it happened!
Ignore the amplitude of the crankshaft sensor signal, that’s just scaling to cope with the running engine.
FYI: all the captures used a common ground connection.
So once again, a bad aftermarket sensor caused all this additional trouble. I can only assume that the original camshaft sensor failure, was temperature related. When I returned to test the sensor out of the engine and it worked, the ambient temperature was considerably lower than when I tested it in the engine, (heatwave conditions >35 °C). That would fit with the original failure symptoms. I’m not sure about the power loss, maybe it was just really hot and stressed with the caravan. Maybe there is more to go wrong with the vehicle!