Same unit as me the TUD5B, this has electronic timing control completely, the sensor between the delivery pipes measures this (same as the needle lift sensor on the 1.9XUD units) and adjusts the timing via the timing control unit also fitted. ECU atop the battery.
Check temp senders fitted to thermostat housing, there are two fitted. A fault in the right hand one (when viewing from engine bay so the nearside sender in effect passenger side) can cause a running concern as this is used by the ECU to determine engine temp and keep the timing suitable as these units do not have a cold start fast idle cable, they do sound horrific when stone cold though that's normal.
I'm 90% sure its the right hand one the other one drives the warning light only (single pin but two wires fitted in plug as its capable of having a gauge fitted but they don't have one on these late models)
It will run badly without any of the sensors connected in most cases although the timing will be all over the place.
What did they use to check for faults ? A Planet will show when its running what is going on ie timing asked for and what is being given. See pic:
If you have a fuel system full of air it can also really upset this system too. Its a Bosch pump. Examine the following areas:
On the injectors, check the leak off piping for splits and leaks, any air being dragged in here will really upset it. Pay attention to the end 'cap' on the last injector after the loop.
You'll see the clear fuel piping near the pump there's a section where you can see both feed and return (the one you see on the top of the pump on the 'extension' is the return. When its running are there any bubbles here ? Operate the primer (with it not running!) and look at the pipe for bubbles.
The other cause is the waxstat for the fuel heater (similar to the XUD one a white plastic spring affair) these can take air in. Its on the back of the filter housing so not easy to see. The 'usual' cure is a finger of sealant applied to its orifice, after checking its clean and dry, if there was a concern here with its o-rings (its not really possible to replace it easily) then this can fix it in most cases.
EGR valve, rarely gives problems on these though, pull the vacuum pipe from the valve to ensure its closed or just unplug the electrical connector on the bulkhead, this will *not* cause the warning light to come on.
Regarding it running OK, when its stone cold does it run at a sensible speed ? , these units don't really have a 'fast idle' to any degree. And when its warm after say five minutes running does it sound nice and not knocking to excess ? (a faulty sensor will do that as it will ignore and preset a timing setting)
Andy.
91 205D-Turbo, gone but still missed
02 106D, TUD5B, gone but not really missed apart from the MPG