Hi,
I have the obd uart v2 and plan to use it on a GM ls1 engine. I am testing this on a 2015 Chevy 2500. I'm using a mega2560 and have white connected to tx0 and green connected to rx0 like the instructions say but when I try to use the obd_uart_test I get this return on the serial monitor.
Sending ATZ
Timeout
Sending ATL1
Timeout
Sending ATH0
Timeout
Sending ATRV
Timeout
Sending 0100
Timeout
Sending 010C
Timeout
Sending 0902
Timeout
Init...
Init...
Init...
Init...
Init...
Init...
Init...
I'm not sure where I need to be looking or what might need to be changed to get the adapter to properly initialize. I believe the GM obd2 protocols are supported. Any help would be appreciated.
Obd UART stuck in init loop
Re: Obd UART stuck in init loop
If you take a look in OBD.h and you will see you should connect OBD adapter to Serial1 (Tx1 and Rx1).
Re: Obd UART stuck in init loop
I apologize for the rookie mistake. Thanks. It is initializing and returning things now. But I'm not sure if this is what its supposed to be doing. I ran the uart test and let it run for about 15 minutes and I also tried the rpm led test and it didn't work either. When I tried both of these tests again the blue light on the adapter was on when I plugged it in then it went off and never came back on. Here are the results from the uart test.
Sending ATZ
Sending ATL1
Sending ATH0
Sending ATRV
Sending 0100
Sending 010C
Sending 0902
Init...
[127709]ATZ
[142760]ATE0
[157811]ATL1
[172862]0100
[187913]0100
[205917]RPM=[205918]010C
[303932]RPM=[303932]010C
[401947]RPM=[401947]010C
[499961]RPM=[499961]010C
[597976]RPM=[597976]010C
[695991]RPM=[695991]010C
[794005]RPM=[794005]010C
[892019]RPM=[892019]010C
[990033]RPM=[990033]010C
Sending ATZ
Sending ATL1
Sending ATH0
Sending ATRV
Sending 0100
Sending 010C
Sending 0902
Init...
[127709]ATZ
[142760]ATE0
[157811]ATL1
[172862]0100
[187913]0100
[205917]RPM=[205918]010C
[303932]RPM=[303932]010C
[401947]RPM=[401947]010C
[499961]RPM=[499961]010C
[597976]RPM=[597976]010C
[695991]RPM=[695991]010C
[794005]RPM=[794005]010C
[892019]RPM=[892019]010C
[990033]RPM=[990033]010C
Re: Obd UART stuck in init loop
I have now tried the uart test on three different vehicles with the exact same results. A '13 jeep, the 2015 GM mentioned earlier, and a 2002 GM. After it performs the testout() function and shows "init..." on the serial monitor, it doesn't get the vehicles "VIN" and doesn't seem to perform the readPIDMultiple() function either. It just shows the [millis]RPM=[millis]010c over and over like the previous post shows. I actually opened the serial monitor later on without the OBD2 adapter even plugged into the arduino and it never performed any functions or showed a timeout error like it did in my first post. It just started displaying that same RPM message in what looks like a loop. Could that mean that the adapter isn't getting properly initialized?
Also, the only code that I changed in the UART test example was on line 15. I removed the slashes from | #define mySerial Serial | because I'm not using software serial.
Not sure if I'm still doing something wrong or if this is a hardware problem. Again, thanks for any help.
Also, the only code that I changed in the UART test example was on line 15. I removed the slashes from | #define mySerial Serial | because I'm not using software serial.
Not sure if I'm still doing something wrong or if this is a hardware problem. Again, thanks for any help.
Re: Obd UART stuck in init loop
I've tried several things now. I'm at the point where I don't know what to do next to try and get this to work. I wrote this just to try to get the battery voltage and display it on the serial monitor.
//Battery voltage test
#include <OBD2UART.h>
#define mySerial Serial
COBD obd;
void ShowVoltage(float v)
{
mySerial.println(v);
}
void setup()
{
delay(500);
mySerial.begin(115200);
// this will begin serial
obd.begin();
// initialize OBD-II adapter until success
do
{
mySerial.println("Init...");
}
while (!obd.init());
}
void loop()
{
float v = obd.getVoltage();
ShowVoltage(v);
}
This is the result from the serial monitor. The vehicle was running so the battery voltage obviously isn't 0.00.
Init...
[15702]ATZ
[30752]ATE0
[45803]ATL1
[60854]0100
[75906]0100
0.00
0.00
0.00
0.00
0.00
0.00
Has anybody else had a problem similar to this? Like not being able to get any results from reading any of the PIDs? Again, still not sure if I'm doing something wrong or if there is an issue with the adapter. Just looking for any help I can get. Thanks
//Battery voltage test
#include <OBD2UART.h>
#define mySerial Serial
COBD obd;
void ShowVoltage(float v)
{
mySerial.println(v);
}
void setup()
{
delay(500);
mySerial.begin(115200);
// this will begin serial
obd.begin();
// initialize OBD-II adapter until success
do
{
mySerial.println("Init...");
}
while (!obd.init());
}
void loop()
{
float v = obd.getVoltage();
ShowVoltage(v);
}
This is the result from the serial monitor. The vehicle was running so the battery voltage obviously isn't 0.00.
Init...
[15702]ATZ
[30752]ATE0
[45803]ATL1
[60854]0100
[75906]0100
0.00
0.00
0.00
0.00
0.00
0.00
Has anybody else had a problem similar to this? Like not being able to get any results from reading any of the PIDs? Again, still not sure if I'm doing something wrong or if there is an issue with the adapter. Just looking for any help I can get. Thanks
Re: Obd UART stuck in init loop
I finally resolved the issue. I guess I should've thought to check this earlier but this is my first arduino project. I'm not really sure what made me think to check it but for some reason I wasn't getting a good connection between the uart ground and the arduino. I messed with it and it works now.
Re: Obd UART stuck in init loop
Hi, Could you explain what did u do more explicitly ? Thx