View Single Post
Old 05-18-2008, 03:11 AM   #75 (permalink)
Mr. Cheap
EcoModding Lurker
Join Date: May 2008
Location: Central New Mexico
Posts: 18

Bun - '02 Ford Focus ZTS
90 day: 31.3 mpg (US)
Thanks: 0
Thanked 0 Times in 0 Posts
Thumbs up

I just tested my guino today! I've been following the project for a while, but I haven't had the time to play until school let out last week. I'll post some pictures when I get my usb ports working.

I also noticed the low numbers on the instant mpg readout. My instant mph was fine. It also seemed that only speed affected instant mpg, not throttle. My instant raw injector time was usually 20000 to 26000 uS at light throttle. I did some quick calculations and noticed that gallons() would underflow to zero for the values typically seen in instant.

My fix for this:
unsigned long  Trip::mpg(){
  unsigned long mi=miles();
  unsigned long gal=gallons();
  if( injHiSec<4 ) // prevent overflow
    gal = ((injHiSec*1000000000) + (injHius*1000))/(microSecondsPerGallon/1000); // 1e-6 gals
    if (gal==0) gal=1;//default to a millionth of a gallon so not division by zero
    return mi*1000000/gal; // 1e3 mi * 1e6 / 1e-6 gal = 1e3 mpg
  if (gal==0) gal=1;//default to a thousandth of a gallon so not division by zero
  return mi*1000/gal; // 1e3 mi * 1e3 / 1e3 gal = 1e3 mpg
It seems to work fine on the simulated values. I have not yet tested this in the vehicle.

Other things I've noticed:
My injector line is low when the engine is off. The guino incorrectly counts this as injector firing.
When changing screens the banner text is hard to see because of the leftover text and symbols cluttering the screen.

I'm willing to help with programming this project.
  Reply With Quote