OBDII Link Error

233k miles
2004
just replaced engine wiring harness

March 2019 engine shuts off on freeway, won't turn over, no dash lights, nothing.
Local mercedes shop says engine wiring harness has rubbed through and is shorting out. They make some repairs to the harness. When I get it back it pretty consistently goes in limp mode. Eventually I loosen the zip ties around the area they repaired to look at their work. After doing this the limp mode goes away. Not inspiring confidence in their work or the future reliability of the wiring harness. eventually i can't get any link to the ECU to read codes but the scanner will power on and it will show battery voltage. I got some help with this here but was never resolved.

December 2019 the engine shuts off again on the freeway and i get it towed to a Mercedes dealer they says they've located more damaged wiring and repair. I drive it all the way from SLC to SF ( was on vacation when this occured) and it goes into limp mode 700 miles after the repair. I use my icarsoft MBII and still can't get any codes or info but like before the scanner will power on and show voltage.

I replaced the engine wiring harness yesterday to just have a clean slate as far as the limp mode goes and not trusting what other wiring damage exists that wasn't addressed in the previous repairs.

I'm at a loss for what to look into next. I need the OBDII to work to pass smog in CA and just for general peace of mind going forward. I tried getting it smogged yesterday and they couldn't communicate with the ECU. I followed the wiring coming from the OBDII port and looks to go out of the firewall through the non engine wiring harness. Any leads as to things to ohm out and check for continuity?

Thanks
Michael
 

calbiker

Well-known member
If the scanner only displays battery voltage then most likely the scanner does not request battery voltage from the ECU. The scanner measures this voltage using its A/D. In this case there is no OBD communications.

Where in CA are you located? I have the tools to check OBD communications.
 
If the scanner only displays battery voltage then most likely the scanner does not request battery voltage from the ECU. The scanner measures this voltage using its A/D. In this case there is no OBD communications.

Where in CA are you located? I have the tools to check OBD communications.
That makes sense. I'm located in Berkeley.
 

calbiker

Well-known member
You could build a OBD "sniffer" to watch communications between your scanner and the vehicle controllers. The effort consistis of soldering up a couple transistors and a few resistors to obtain k-line voltage level shift so that Arduno can read the communications. I can supply a schematic and Arduino code.
 
You could build a OBD "sniffer" to watch communications between your scanner and the vehicle controllers. The effort consistis of soldering up a couple transistors and a few resistors to obtain k-line voltage level shift so that Arduno can read the communications. I can supply a schematic and Arduino code.
I would be down to try that! I've messed around with arduinos in the past. I'm assuming i would need an arduino, usb-obdII connector and maybe a breadboard?

Aside from reading the communication coming through the OBDII port I'm also wondering if perhaps it's a wiring issue that is preventing any communication coming to the port itself.

Michael
 

Nautamaran

2004 140” HRC 2500 (Crewed)
You’re in good hands with Calbiker to diagnose this. :thumbup:

The ECM’s k-line (one of seven) is on pin 7 of the datalink (obdii) connector and loops back to the ECM plug (Connector C2, Pin 31, 20 gauge BLUE/YELLOW).

To monitor scanner communications you’ll need a Y-cable or access to your scanner’s plug internals or the back of the Datalink socket. The monitor circuit Cal and I used earlier connects to RX on one of the Arduino’s serial ports (or to a Softwareserial instance on a Uno) then you watch the echoed communications via the Arduino’s USB port using a laptop running a terminal program (such as Putty or the Arduino IDE).

Good luck with it, :cheers:

-dave
 

calbiker

Well-known member
Right, we're getting ahead of ourselves with Arduino at this moment. First let's do some multimeter measurements on the OBD pins. It's best to purchase a OBD Y-cable.

https://www.ebay.com/itm/OBD2-OBDII-Splitter-Extension-Cable-16pin-Male-to-Dual-Female-Y-Cable-30cm-1ft/122032995944?_trkparms=ispr%3D1&hash=item1c69bbbe68:g:BAYAAOSwTFNZdiDq&enc=AQAEAAACQBPxNw%2BVj6nta7CKEs3N0qWdzln4OaRdeVFkk1hjErd2vQ8hvklonEfz1SyyTiQL3H7MIRFifgb3vCkiKfOdpZauUiKy0iFcTIzFy014451b9RyQxxVU8Z3CMMTdo8WA6WagYGZcnx4qrMSc1KkBo%2BkrRigtKlg6VojiwqR6bYmiHNb3OjIN8feneTEWRpstNHhE%2FcrgUWsbHS7prF%2FrgVwSL57GkTvZiqCj2nGP715jw8RAU6DU9O9%2FesYSolkg1kDh58W9UyjBFSh0YA25tE%2FPCc2ar4%2BSkP58w7NH3TuiaU%2BNr4RLRju8BE9KDpzF7qunA41Mvcwz5zHuaNBqMf5XWLQxKpNXufjFQZm4UBZUlvi6M2r2XO%2B%2FE3P2qUY4Di0Z%2BlcEoqjHKEoVbVRO49WnfXsHBaV4gu1jfgMb8K3kS00VXbQ%2FiM3diaPb%2BWCdlJhIfeO6sN4IzLAPkW%2FsSZYV2csGm5F3BGUldgysFVt%2F8l9FtBK0rXLu1F4rJj2AePEJsiKJEGyvrsvavIzGTxhgNGfkgACHUFDsHfq9%2FkQVVrPdG375YRXm7f8qjYpJmvFMEEQYhvm5h4OQW%2FFCiOlsn1KYklM7o8w%2FZr%2Fw6z5oHVpOtvBAq10wyRa884r7dldm%2FdcAhnxWkK7TQiAj2tfmhECci7GbGuUIr%2FCK9SQxxgvHcA8kjaPGDU4E0iNfZVJpcsJWIBA1DMHi6CimSGOf66Abjg8DYCD59%2B1Ur9MUOLkMGxZeSSHtss0M5zV5xg%3D%3D&checksum=1220329959440f396b31f251480ba44ddb60109e1f51

Cut one of the female connectors off. Strip the individual wires. Using an ohmmeter label each wire with the corresponding OBD pin. If my notes are correct, here's what we need:

1: K-SKREEM
3: RPM
4: Gnd
5: Gnd
7: K-ECM
8: 12V Run-Start
9: K-ABS/Shifter
11: K-TCM
15: K-IC
16: 12V

There's a few more modules but we don't need them. OBD pin 7, K-ECM is the engine control mudule, that's what's required for smog. Most likely also RPM.

I'll have a procedure for you by the time you get the Y-cable.

Edit: You don't have to cut the female connector off if you can secure individual wires into the female connector.

Aside from reading the communication coming through the OBDII port I'm also wondering if perhaps it's a wiring issue that is preventing any communication coming to the port itself.

Michael
 
Last edited:

calbiker

Well-known member
I took some multimeter measurements on the OBD connector. It's not as revealing as I though it would be.

pin to pin measurements:
4 - 5 (gnd to gnd): less than 0.5 ohms
16 - 4 (12V to gnd): 12V with ignition on or off
8 - 4 (run start to gnd): 12V with ignition on, 0V with ignition off
7 - 4 (ECM to gnd): greater than 1 meg ohm with ignition on or off
11 - 4 (TCM to gnd): same
15 - 4 (IC to gnd): same
 
I took some multimeter measurements on the OBD connector. It's not as revealing as I though it would be.

pin to pin measurements:
4 - 5 (gnd to gnd): less than 0.5 ohms
16 - 4 (12V to gnd): 12V with ignition on or off
8 - 4 (run start to gnd): 12V with ignition on, 0V with ignition off
7 - 4 (ECM to gnd): greater than 1 meg ohm with ignition on or off
11 - 4 (TCM to gnd): same
15 - 4 (IC to gnd): same

I have confirmed all of the above and I've established continuity between k-ecm and C2 Pin 31.


I guess next steps would trying to see what info is available through the arduino.
 

calbiker

Well-known member
It's not difficult to listen in on communication between your scanner and the ecm k-line.

You'll need to reduce the 12V k-line voltage to 5V so that Uno can accept it. Solder 47k and 33k ohm resistors together to make a voltage divider. Solder the top side of the 47k to OBD pin 7 (ecm). Solder the lower side of the 33k to OBD pin 4 or 5 (ground). Connect Uno pin 2 (defined as RX) to the junction of the two resistors.

Data should be streaming from the serial monitor which should be set to 115200 baud.


Arduino sketch to sniff the K-line:
#include <SoftwareSerial.h>

SoftwareSerial mySerial(2,3); // RX, TX

const uint32_t DataDelay = 10000; //Delay in us to determine when transmission ends
uint32_t startMicros; //
static boolean busyFlag = false;

void setup()
{
Serial.begin(115200);
Serial.println("Hey There");

mySerial.begin(10400);
}
void loop()
{

if (mySerial.available() > 0)
{
int inByte = mySerial.read();
Serial.print(inByte, HEX);
Serial.print(' ');
busyFlag = true;
startMicros = micros();
}

else
{
if (busyFlag == true && micros() > (startMicros + DataDelay))
{
Serial.println(' ');
busyFlag = false;
}
}
}
 
It's not difficult to listen in on communication between your scanner and the ecm k-line.

You'll need to reduce the 12V k-line voltage to 5V so that Uno can accept it. Solder 47k and 33k ohm resistors together to make a voltage divider. Solder the top side of the 47k to OBD pin 7 (ecm). Solder the lower side of the 33k to OBD pin 4 or 5 (ground). Connect Uno pin 2 (defined as RX) to the junction of the two resistors.

Data should be streaming from the serial monitor which should be set to 115200 baud.


Arduino sketch to sniff the K-line:
#include <SoftwareSerial.h>

SoftwareSerial mySerial(2,3); // RX, TX

const uint32_t DataDelay = 10000; //Delay in us to determine when transmission ends
uint32_t startMicros; //
static boolean busyFlag = false;

void setup()
{
Serial.begin(115200);
Serial.println("Hey There");

mySerial.begin(10400);
}
void loop()
{

if (mySerial.available() > 0)
{
int inByte = mySerial.read();
Serial.print(inByte, HEX);
Serial.print(' ');
busyFlag = true;
startMicros = micros();
}

else
{
if (busyFlag == true && micros() > (startMicros + DataDelay))
{
Serial.println(' ');
busyFlag = false;
}
}
}
Assembled as described above. wire going from middle of two resistors to Rx.
I compiled, uploaded the code and opened serial monitor at 115200. It displayed "Hey There"
I did a scan with my iCarsoftMBII (ignition on) but didn't get anything else on the serial monitor. Hopefully I'm doing something wrong.
 

Nautamaran

2004 140” HRC 2500 (Crewed)
Don’t connect to RX... that’s i/o Pin zero and part of your USB connection to your computer.

Your monitor should be connected to Digital I/O Pin 2, which is the input line to the SoftwareSerial instance mySerial created in the second line.

-dave
 
Don’t connect to RX... that’s i/o Pin zero and part of your USB connection to your computer.

Your monitor should be connected to Digital I/O Pin 2, which is the input line to the SoftwareSerial instance mySerial created in the second line.

-dave
Connected to digital pin 2, still no luck.

Michael
 

calbiker

Well-known member
You should at least see data from your scanner. Either the scanner is defective or there’s a setup issue.

Edit:
What is the voltage at the ecm k-line when the iCarsoftMBII scanner is attempting to communicate with it? The signal transitions between 0 and 12V. There should be some voltage.
 
Last edited:
You should at least see data from your scanner. Either the scanner is defective or there’s a setup issue.

Edit:
What is the voltage at the ecm k-line when the iCarsoftMBII scanner is attempting to communicate with it? The signal transitions between 0 and 12V. There should be some voltage.
I'll check that tonight.

Here's the schematic i made from you description for the resistors and OBD outputs:
 
Here's what i got using my generic OBDII scanner:

10:01:19.396 -> Hey There
10:01:41.191 -> 0
10:01:41.775 -> 0
10:01:42.598 -> 0
10:01:47.921 -> 0
10:01:47.956 -> C1 33 F1 81 66
10:01:58.357 -> 0
10:01:58.975 -> 0
10:01:59.766 -> 0
10:02:05.105 -> 0
10:02:05.173 -> C1 33 F1 81 66

Then the scanner showed "Link Error" just like my iCarsoftMBII
 

calbiker

Well-known member
Your scanner (with address F1) is initiating a communication request.

format byte = C1
target address byte = 33
source address byte = F1
service ID byte = 81
check sum = 66

The ECU never replies. There is no communication. Either the ECU is defective or there's an open wire. Have you done a wire continuity check?
 

Top Bottom