MPG  -  Car petrol consumption monitor

by Steve Hunt

Version 1.00

Monitoring your car's petrol consumption can give an early indication of fuel system or ignition system problems, as well as telling you a lot about your style of driving! MPG is an application that makes keeping track of your car's fuel consumption easy for you.

Running the item from the RISC User menu system, or double-clicking on the !MPG application icon (a top-less mini) in a Filer window installs the application as normal, and clicking over the icon bar icon will open the main MPG window.

Data within this window is presented in 3 columns: Distance, Fuel and Consumption. The units can be selected from the main menu as Miles or Kms, Gallons or Litres, and Miles per Gallon (MPG) or Kms per Litre (Kpl).

When you first use MPG a starting mileage of 10,000 will be displayed. You should use the menu options to reset this mileage to the current mileage of your vehicle, and to select your preferred units. At start-up, MPG will default to Miles, Litres and MPG, but you can change this default as described later.

When you next fill up your vehicle with fuel, note the new mileage and the quantity of fuel used. Enter the new mileage into the writable icon at the bottom left of the window, press Return and enter the fuel used into the other writable icon. Press Return again; MPG will then calculate the fuel consumption and display it in the adjacent icon. You will be warned if the new mileage is not greater than the previous mileage, or if the fuel consumed is zero. You can then add this new record to any previous records by clicking on the Update icon. Once you have entered a number of historical records in this way, the topmost icon will display the total distance travelled, the total fuel consumed, and the average fuel consumption for all records.

You can highlight individual previous records by clicking over them with the Select mouse button, or you can highlight a range of previous records by clicking Select over the oldest (top-most) record followed by Adjust over the newest (bottom-most) record. The top icon will then display the distance travelled, the fuel used and the average consumption for the highlighted records; the figures will be displayed in red to remind you that they refer only to a subset of the full historical record. This  feature is useful if, say, you want to compare the fuel consumption achieved over the most recent 1000 miles with that achieved 10,000 miles ago.

Selected records may be deleted either by using the menu option, or by <Ctrl-X> if MPG has the input focus; however the Delete option is not available if all records are highlighted. The highlighting can be cleared by clicking Adjust over the top-most highlighted record, or from the menu.

Historical records can be saved using the menu Save option which operates in the usual RISC OS manner. If you wish to alter the default units used by MPG at start-up, and you feel confident about editing Obey files, you can alter the line in MPG's !Run file that sets the MPG$Opts variable. This variable consists of the letters F, D and C, each followed by a 0 or a 1, which have the following meanings:

	F0=Gallons
	F1=Litres

	D0=Miles
	D1=Kms

	C0=Miles per Gallon (MPG)
	C1=Kms per Litre (Kpl)

So, for example, F0 D1 C0 would mean we wanted to use Gallons, Kms, and MPG.

Two sample files are included to give you an idea of how the program works. These are entitled Golf and Mini and are located inside the !MPG application directory.

Copyright  RISC User 1996
