Personally I like to verify by proper Diagnosis exactly where the fault lies before buying and changing parts
When checking for 12V and Earths I prefer a 5w test lamp, multimeters can report a useless "feedback" voltage because they do not load a circuit, the test bulb must light brightly
It does sound like K40 area, so first up (if you haven't already done so), get the correct Wiring Diagram for your Car's VIN, (Mercedes WIS diagram), "generic & pin out" type diagrams often lead one up the garden path !!
Check V Inputs and outputs to / from K40 using Wiring Diagram to find the appropriate pins / wires.
Strip K40 and Inspect the solder joints with a good magnification, dry joints show tiny cracks not always obvious to the naked eye, re flow them.
Test all the K40's relays, (Coils and Contacts).
Bell out Wiring between K40 and ECU for good continuity.
By the time you have done this you should know exactly where the fault lies.
HTH, Cheers Dave