Page 1 of 1

Inconsistent obd.read()

Posted: Sun Sep 06, 2015 5:22 am
by jmoges
I'm using the UART obd2 adapter and I've been testing in my car (Toyota Tacoma) and motorcycle (Triumph Daytona 675). In my car I'm able to get the data (RPM and throttle position) without any problems. Using the same code on my motorcycle and

Code: Select all

obd.read(PID_RPM, rpmValue)
doesn't always return true.

Yesterday when I was testing I wouldn't get anything to return. This morning I tried again and obd.read() would return RPM and throttle position when I didn't change any code. Then I tried seeing what was being returned with some print statements and obd.read() was still returning what was expected. Eventually obd.read() started returning 0's. I tried running the arduino a few times and tried different ways of connecting the obd2 adapter (plug in the adapter first, then turn on and start the bike; turn the bike on, plug in the adapter, then start the bike; etc.). I couldn't get obd.read() to return 1's again.

Does this sound like something that happens a lot? Is there anything I can try or look at to get my motorcycle to consistently return RPM and throttle position? Could it be an issue with my obd2 connection on the motorcycle? I'm a little lost with this problem.

Thanks

Re: Inconsistent obd.read()

Posted: Sun Sep 13, 2015 8:00 pm
by stanley
On Arduino Uno, never use Serial.print as the OBD-II UART adapter uses serial for communication. Use of Serial.print will interrupt the communication.

Re: Inconsistent obd.read()

Posted: Mon Sep 14, 2015 7:25 am
by jmoges
I guess I should have said I'm using a Mega. I'm using pins 18-19 for the adapter, pins 0 and 1 are left alone. Would that still cause a problem?