Quote:
Originally Posted by Old Tele man
...I somehow missed finding that page when I fumbled around looking for information; I appreciate the direct link...Thanks!
|
Forgive yet another long post from me, but this is something that just came up for me a few days ago.
The thing to keep in mind is that even as you enter very technical sounding things, like engine size, etc. you are not just calibrating for the vehicle and it's sensors, but also your driving style and common routes.
The problem is that standard OBD-II information doesn't include everything you need for precise measurement, so all MPG systems based on them have to make some assumptions. The problem is, the assumptions aren't always true.
Let's say your vehicle offers a MAF sensor and a VSS sensor. In this case, if we have a modern vehicle that runs 'closed loop' for emissions, it seems like we have everything we need to get a good idea about fuel consumption and the work being done. If we assume that our AFR is 14.7:1, or there about, and we know the mass of air going in, it seems like we could take an educated guess about how much fuel is being used. But let's look at a 30 second log I took from my daughter's car driving an errand I normally walk because of the pouring rain:
A side effect of my work, all the cars here are instrumented, and she has a relatively fast ECU, so when I snagged this log on my phone, we got a bunch of channels I had previously configured for, but if we turn everything off but RPM and VSS, we can see what I was doing:
I was nearly stopped when I started the log, then I had to give some gas to both accell and climb the steeper end of a modest hill. I then coasted down the long side of the hill, breaking to a stop at a stop sign, then accell'ed away, into another very modest terrain rise.
Now let's turn on MAF from the sensor:
The scale is kind of high, but we can see that MAF dropped quite low as we were coasting. With MAF low and VSS still relatively high, the theoretical calculation should put out a pretty high MPG. So let's do two things.
Let's add a math trace, that is, a computation, not something we got from the ECU. We'll just do the rudimentary MPG from VSS and MAF you'll find if you Google it. In addition, let's drop a marker near 20 seconds and see what values we are talking about.
Sure enough, calculated MPG was low when I was on the throttle, soared as I started to coast, spiked when MAF dropped, then decayed as my speed decayed. At the point in question, 3 gs in MAF (actually, it is rounding because of the scale, it was 3 and change) and an MPG calculation of 81.8. The question is, is this right?
The fundamental assumption is that air flowing through represents a certain amount of fuel. But let's look at the narrow band O2 sensor in the car that it uses to run closed loop:
Up to the 15 second mark, the sensor is oscillating between rich and lean. This is normal. The sensors inherently have a steep curve at stoich, and ECU's chase it closed loop. The crossover, lean, rich, lean, rich, actually has to occur for the cat to work right anyway. But starting at 15 seconds, the sensor is pegged lean. So, we aren't running at 14.7:1, but how much leaner?
Fortunately, this ECU has a less common J1979 PID called EQ_RATIO. It isn't something measured, but the Equivalency Ratio that the ECU is trying to achieve:
Equiv. Ratio is normally shown as it's reciprocal, and called "lambda". To approximate AFR, you multiply lambda by the typical stoich ratio of the fuel. So, before 15 seconds, the 1.0 means 1.0 x 14.7, or 14.7:1. But when our MAF dipped, the ECU says it was targeting 1.11, or 1.11 x 14.7 = 16.3:1. So, taking the ECU at face value, we can see that the MPG is wrong, because we are leaner than 14.7:1.
But, in this case, I think the error is bigger still. 1.11 is the highest the ECU ever reports for that PID, but look at RPM at that point, it dips and gets rougher. I would bet good money (well, OK money), that I was in overrun and the injectors were closed. That is, lambda was infinite because no fuel was being used.
Now, look right after the stop sign, the O2 sensor pegs rich and the ECU reports that it is targeting about .8 lambda, or 11.76:1. It is tempting to think that coasting lean and going up hill rich will even back out to 14.7:1. But this isn't so. If you turn AFR over, and make it fuel to air (and fuel is what we are projecting based on air) and you average a trip over hilly terrain, you aren't going to end up back at stoich. The reason is the same one that MPG calcs tend to jump so wildly, MPG is not a linear scale, but a exponentially curved one.
Also, it might be tempting to say, but that's MAF, I use X, Y, and Z... But the truth is that MAF is one of the best ways to know fuel. The problem is that many vehicles don't offer a MAF sensor, so we have to work from things like MAP, IAT, and RPM.
I don't know the exact calculation used in this device, but the general formula would be something like:
IMAP = RPM * MAP / IAT (in degK)
Then, airmass = (IMAP/120) * (VE/100) * Displacement * constants-for-air
This calculated air value is then used in lieu of MAF for a fuel usage estimation and MPG calculation. There is nothing wrong with this sort of calculation, a lot of ECU's do essentially the same thing. But they have some information that we do not readily have via OBD-II. For example, they have a VE lookup table for different loads and conditions. Also, just like the example above, they know the AFR that they are targeting at the moment!
Via OBD-II, we have some additional challenges. MAF is a 16 bit measurement, 1/100 g/s, but MAP is pretty course, just one byte and in kPa steps. Second, there is the question of ecu speed. Take a typical pre-CAN Honda, say early 2000-somethign models. They are talking ISO 9141, and pretty slow. If you are polling MAP, RPM, IAT, and VSS. You are getting a full set of readings roughly 1 or 2 times a second. So you are getting snapshots of engine performance that are pretty far apart. In addition, the samples themselves are offset from each other in time.
Now, there are some tricks that could be used to refine the measurements, but, in general, I think these sorts of things are better as 'relative' measurements. I am using more fuel, less fuel, that sort of thing.
Sorry for the long post, but I just talked to someone else about this a few days ago.
-jjf