2

I'm trying to write an app that communicates with the OBD port in a car and (among other things) find the AFR, but my car doesn't seem to support the fuel-air equivalence ratio command 01 44. I see that there are two sets of PIDs for the oxygen sensors that give a fuel-air equivalence ratio. The first set is PIDs 01 24 through 01 2B, which give

Oxygen Sensor [1-8]

AB: Fuel–Air Equivalence Ratio

CD: Voltage

The second set is PIDs 01 34 through 01 3B. These look similar, but instead give the following data:

Oxygen Sensor [1-8]

AB: Fuel–Air Equivalence Ratio

CD: Current

Is the fuel-air ratio the same value on all of the sensors (at least ideally), or are they designed to measure different values? Which PID(s) should I use to calculate the AFR or FAR, and what calculations are required apart from what I see in the link (which is 2/65536 * (256A + B) for the ratio)? What are the voltage and current values, and are they of any use to me in this situation?

Any help is much appreciated.

Community
  • 1
  • 1
wlyles
  • 2,236
  • 1
  • 20
  • 38
  • See https://github.com/pires/obd-java-api/blob/master/src/main/java/com/github/pires/obd/commands/fuel/WidebandAirFuelRatioCommand.java .It may helps you – pRaNaY Apr 11 '16 at 11:46
  • I'm actually using that API in my app, but it doesn't support any of these commands. I was going to write my own and experiment with the results to see what these commands do – wlyles Apr 11 '16 at 21:54

2 Answers2

1

Depending on what you are trying to achieve, the oxygen sensor may not be the right choice, regardless of reading.

Oxygen sensors are usually located in the exhaust manifolds or exhaust piping. They read data from the exhaust gasses leaving the engine. This is helpful in determining if the engine is running correctly.

However, if you are trying to determine the AFR entering the engine, which is what it sounds like, the oxygen sensors would not be very helpful. A very high or very low reading could indicate that the intake AFR is not correct, but getting an actual number would be difficult.

SouthShoreAK
  • 4,176
  • 2
  • 26
  • 48
0

I am totally agree with SouthShoreAK answer which your approach is not correct for what you want. Nevertheless, If you insist on these PIDs, here are some tips about it:

All the OBD PIDs definitions are within ISO 15031 part 5 (which you have to buy it of find it somehow!). Please consider that the OBD data are mostely used (even the main reason!) for emissions-related diagnostics.

Firstly you can check mode 1 PID 00 to check the supported PIDs in your vehicle. you will get a single response from main controller and they are bitwise. You can check wikipedia to see how you can parse this PID.

below is some info about PID 0x24 - 0x2B and 0x34 - 0x3B:

  • PID 0x13 shall only be supported by a given vehicle if PID 0x1D is not supported. In no case shall a vehiclesupport both PIDs.

  • The PIDs 0x24 - 0x2B or 0x34 - 0x3B data should be parsed using PID 0x13 or 0x1D.

  • You cannot parsing these data without accessing ISO and parsing methods in wikipedia in this case is very lazy-defined and might not be correct.
Community
  • 1
  • 1
mohsen_og
  • 774
  • 1
  • 9
  • 31