Silicon ChipUnderstanding Engine Management - Performance Electronics for Cars SILICON CHIP
  1. Outer Front Cover
  2. Feature: Publisher's Notes & Disclaimer
  3. Feature: Introduction
  4. Contents
  5. Feature: Understanding Engine Management by Julian Edgar & John Clarke
  6. Feature: Advanced Engine Management by Julian Edgar & John Clarke
  7. Feature: Other Electronic Systems by Julian Edgar & John Clarke
  8. Feature: Modifying Car Electronic Systems by Julian Edgar & John Clarke
  9. Feature: DIY Electronic Modification by Julian Edgar & John Clarke
  10. Feature: Building Project Kits by Julian Edgar & John Clarke
  11. Feature: Using A Multimeter by Julian Edgar & John Clarke
  12. Project: Smart Mixture Meter by Julian Edgar & John Clarke
  13. Project: Duty Cycle Meter by Julian Edgar & John Clarke
  14. Project: High Temperature Digital Thermometer by Julian Edgar & John Clarke
  15. Project: Versatile Auto Timer by Julian Edgar & John Clarke
  16. Project: Simple Voltage Switch by Julian Edgar & John Clarke
  17. Project: Temperature Switch by Julian Edgar & John Clarke
  18. Project: Frequency Switch by Julian Edgar & John Clarke
  19. Project: Delta Throttle Timer by Julian Edgar & John Clarke
  20. Project: Digital Pulse Adjuster by Julian Edgar & John Clarke
  21. Project: LCD Hand Controller by Julian Edgar & John Clarke
  22. Project: Peak-Hold Injector Adaptor by Julian Edgar & John Clarke
  23. Project: Digital Fuel Adjuster by Julian Edgar & John Clarke
  24. Project: Speedo Corrector by Julian Edgar & John Clarke
  25. Project: Independent Electronic Boost Controller by Julian Edgar & John Clarke
  26. Project: Nitrous Fuel Controller by Julian Edgar & John Clarke
  27. Project: Intelligent Turbo Timer by Julian Edgar & John Clarke
  28. Feature: Resistor & Capacitor Codes

This is only a preview of the Performance Electronics for Cars issue of Silicon Chip.

You can view 38 of the 160 pages in the full issue, including the advertisments.

For full access, purchase the issue for $20.00.

Items relevant to "Smart Mixture Meter":
  • PIC16F84(A)-04/P programmed for the Fuel Mixture Display [AIRFUEL.HEX] (Programmed Microcontroller, AUD $10.00)
  • PIC16F84 firmware and source code for the Fuel Mixture Display [AIRFUEL.HEX] (Software, Free)
  • Fuel Mixture Display PCB patterns (PDF download) [05109001/2] (Free)
  • Fuel Mixture Display panel artwork (PDF download) (Free)
Items relevant to "Duty Cycle Meter":
  • PIC16F84A-20(I)/P programmed for the Duty Cycle Meter [dutycycl.hex] (Programmed Microcontroller, AUD $10.00)
  • Firmware (HEX) files and source code for the Duty Cycle Meter [dutycycl.hex] (Software, Free)
  • Duty Cycle Meter PCB patterns (PDF download) [05car021-3] (Free)
Items relevant to "High Temperature Digital Thermometer":
  • High Temperature Automotive Thermometer PCB pattern (PDF download) [05car041] (Free)
Items relevant to "Versatile Auto Timer":
  • PIC16F84(A)-04/P programmed for the Versatile Auto Timer [oneshott.hex] (Programmed Microcontroller, AUD $10.00)
  • Firmware (HEX) files and source code for the Versatile Auto Timer [oneshott.hex] (Software, Free)
  • Versatile Auto Timer PCB pattern (PDF download) [05car081] (Free)
Items relevant to "Simple Voltage Switch":
  • Simple Voltage Switch PCB pattern (PDF download) [05112081] (Free)
Items relevant to "Temperature Switch":
  • Temperature Switch PCB pattern (PDF download) [05car101] (Free)
Items relevant to "Frequency Switch":
  • Frequency Switch PCB pattern (PDF download) [05car051] (Free)
Items relevant to "Delta Throttle Timer":
  • Delta Throttle Timer PCB pattern (PDF download) [05car071] (Free)
Items relevant to "Digital Pulse Adjuster":
  • Pair of PIC16F628A-I/P programmed for the Digital Pulse Adjuster [pwmmod.hex & pwmadjst.hex] (Programmed Microcontroller, AUD $20.00)
  • Firmware (HEX) files and source code for the Digital Pulse Adjuster [pwmmod.hex/pwmadjst.hex] (Software, Free)
  • Digital Pulse Adjuster / Electronic Boost Controller PCB pattern (PDF download) [05car131] (Free)
Items relevant to "LCD Hand Controller":
  • LCD Hand Controller PCB pattern (PDF download) [05car141] (Free)
  • LCD Hand Controller front panel artwork (PDF download) (Free)
Items relevant to "Peak-Hold Injector Adaptor":
  • Peak-Hold Injector Adaptor PCB patterns (PDF download) [05car151-2] (Free)
Items relevant to "Digital Fuel Adjuster":
  • PIC16F628A-I/P programmed for the Digital Fuel Adjuster [voltmod.hex] (Programmed Microcontroller, AUD $10.00)
  • Firmware (HEX) files and source code for the Digital Fuel Adjuster [voltmod.hex] (Software, Free)
  • Digital Fuel Adjuster PCB pattern (PDF download) [05car121] (Free)
Items relevant to "Speedo Corrector":
  • PIC16F84A-20(I)/P programmed for the Speedo Corrector [corector.hex] (Programmed Microcontroller, AUD $10.00)
  • Firmware (ASM and HEX) files for the Speedo Corrector [corrector.hex] (Software, Free)
  • Speed Corrector PCB pattern (PDF download) [05car091] (Free)
Items relevant to "Independent Electronic Boost Controller":
  • Pair of PIC16F628A-I/P programmed for the Electronic Boost Controller [pwmcntrl.hex & pwmadjrl.hex] (Programmed Microcontroller, AUD $20.00)
  • Firmware (HEX) files and source code for the Electronic Boost Controller [pwmcntrl.hex/pwmadjrl.hex] (Software, Free)
  • Digital Pulse Adjuster / Electronic Boost Controller PCB pattern (PDF download) [05car131] (Free)
Items relevant to "Nitrous Fuel Controller":
  • Nitrous Fuel Controller PCB pattern (PDF download) [05car111] (Free)
Items relevant to "Intelligent Turbo Timer":
  • PIC16F84A-20/(I)P programmed for the Intelligent Turbo Timer [turbotmr.hex] (Programmed Microcontroller, AUD $15.00)
  • Firmware (ASM and HEX) files for the Intelligent Turbo Timer [turbotmr.hex] (Software, Free)
  • Intelligent Turbo Timer PCB pattern (PDF download) [05car031] (Free)
Chapter 1 The electronic control unit (ECU) is the brain that makes the decisions about how much fuel the injectors should add and when the spark plugs should fire. The ECUs in current cars also have many other additional outputs. Understanding Engine Management Getting a handle on how the various engine systems work. D ON’T BE MISLED – the basics of engine management are very easy to understand. Despite people talking about MAPs and MAFs and EGO sensors and all sorts of weird things, getting a grasp of what’s going on will take you only as long as it takes to read these pages. EFI & Engine Management First up, what’s EFI? Well, the term “EFI” simply stands for “Electronic 6 PERFORMANCE ELECTRONICS FOR CARS Fuel Injection”. It’s a system where the addition of fuel to the engine’s intake air stream is controlled electronically, instead of using a carburettor. “Engine management” is the term used when both the fuel and the ignition (spark) timing are controlled electronically. In addition, the management system often also controls the auto transmission, turbo boost, cam-shaft timing and throttle operation. All performance cars made in the last 15 years use engine management. Before we get into an overview on how engine management systems work, let’s take a quick look at the layout of the fuel and ignition systems. Fuel EFI cars use a multi-point system of injection. Each cylinder has its own injector that opens to squirt a mist of fuel onto the back of the intake valves. siliconchip.com.au Fig.1: these two diagrams show the different fuel delivery approaches. On the left is the traditional approach, which places the fuel pressure regulator in the engine bay and uses a fuel return line from the fuel rail to the tank. On the right is the single fuel line approach now being adopted in many cars, where the fuel pressure regulator is at the tank end of the car and no return line is used. [Lexus] When the valves next open, the fuel and lots of air are drawn into the combustion chamber. So what’s an injector? An injector is simply a solenoid valve: when power is applied, the valve opens, allowing fuel to flow through it. When power is removed, the valve shuts and the flow stops. When the engine is running, the injectors each open and briefly squirt fuel once every two crankshaft revolutions (ie, once per intake stroke). The injectors are either fired sequentially (each squirts just before its associated intake valves open), all together, or in one or two groups. The amount of fuel supplied to the engine is dependent on how long each injector stays open. If an injector was open for half of the available time, it would be said to have a “duty cycle” of 50%. If it was squirting for only 2% of the time, the duty cycle is said to be 2%. On a standard car, duty cycles are often around 2-4% at idle and 80% or 90% at full load, full RPM. When the duty cycle reaches 100%, the injector is Fig.2: fuel injectors can be either fired sequentially (one after the other, opening just before each cylinder’s intake valves), all together, or in one or two groups. This circuit shows a sequential system, with each injector controlled by its own power transistor. Note that battery voltage is fed to each injector and the transistor actually grounds the injector to turn it on. [Hyundai] siliconchip.com.au PERFORMANCE ELECTRONICS FOR CARS 7 Where a coil is used for each plug, the car is said to have “direct fire” ignition. The coils can be either mounted directly on the plugs or can be connected to the plugs using high tension (HT) leads. Fig.3: a fuel injector is an electricallyoperated solenoid valve. When power is applied, the valve opens and fuel sprays out; when the power is off, the valve closes. This diagram shows a “top-feed’ injector but “side-feed” injectors are also used in some cars. [Hyundai] Fig.4: the way in which fuel sprays onto the back of the intake valves can be seen here. When the valves open, the fuel and lots of air are drawn into the combustion chamber. [Mazda] 8 PERFORMANCE ELECTRONICS FOR CARS flat out – no more fuel can flow because it is already open continuously. For fuel to squirt out in a fine spray whenever the injector opens, the fuel must be fed to the injector under high pressure. This process of pressurisation starts at the other end of the car, in the fuel tank. Here, a roller-type pump works flat out all of the time – in most cars, it’s pumping just as much fuel at light engine loads as at full load. The fuel leaves the pump, passes through a filter and is then fed into the fuel rail on the engine. The fuel rail is a long, thin reservoir that joins the injectors together. Mounted on the fuel rail is a pressure regulator which allows some of the fuel The duty cycle of a fuel injector is simply the ratio of its on time compared to its off time, expressed as a percentage. On this car – working under load on a dyno – the injector duty cycle is being measured at 86.9%. siliconchip.com.au to bleed off from the rail and flow back to the tank through a return line. The more fuel that the regulator lets out of the fuel rail, the lower the pressure in the rail will be. Fuel pressure is automatically set by the regulator on the basis of manifold pressure. As manifold pressure rises, so does fuel pressure, so that the fuel pressure is always a fixed amount above the pressure in the intake manifold. In this way, if the injector is open for three milliseconds, the same amount of fuel will flow out of the injector irrespective of whether the manifold pressure is at 10 psi of boost or is in vacuum. The above description is typical of most systems but there are some exceptions which should be mentioned. First, many cars now run fuel systems that lack a fuel return line. In these cars, the fuel pressure regulator is at the tank end of the system. Second, some older cars were fitted with just one or two injectors, positioned for “throttle body injection”. Third, some EFI systems operate the injectors once each crankshaft rotation (that is, twice each intake stroke), rather than only once every two crank rotations. And finally, it’s becoming more common to electronically control fuel pump speed, so that the pump runs more slowly at light loads. Ignition Most cars with engine management use multiple ignition coils. Sometimes there is a coil for each plug, with the coils often mounted directly on the plugs (direct fire), while in other cars, double-ended coils are used; eg, Holden Commodore V6 Ecotec. In the latter case, the number of coils is half the number of spark plugs. Older cars use distributors, where the output of a single coil is distributed in turn to each spark plug by a moving mechanical rotor arm. Each coil has an ignition module, which is a computer-controlled switching device that can handle the high voltage and current requirements. The ignition modules (sometimes called “igniters”) can be built into the coils but are more usually contained within a separate box mounted nearby. The key parameter that the engine management system varies is the timing of the spark, referenced against the rotation of the crankshaft and the siliconchip.com.au Fig.5: in this direct-fire ignition system, the coils (complete with integrated “igniters”) are mounted on each plug. Other approaches use double-ended coils (where the number of coils is half that of the number of plugs), while older systems may use only one coil. [Lexus] position of the piston – ie, the spark timing is said to be so many crankshaft degrees before piston Top Dead Centre (TDC). Inputs & Outputs The best way of visualising an engine management system is to consider it on the basis of its inputs, outputs and decision-making. We’ve already covered the two major outputs – the fuel injectors and the ignition coils – but what about the inputs and the decision-making? The decisions on how long to open the fuel injectors and when to fire the ignition coil(s) are made by the Electronic Control Unit, or ECU. If you like, it’s the brain. ECUs are sometimes referred to by different abbreviations (eg, ECM for engine control module) but their function is Fig.6: this older ignition system uses an “igniter” transistor to switch a single ignition coil, with the resulting high-tension voltage then fed to the spark plugs by the rotor arm of the distributor. Here, both the “igniter” transistor and the coil are mounted inside the distributor housing. [Mazda] PERFORMANCE ELECTRONICS FOR CARS 9 Fig.7: the air-flow meter is usually positioned straight after the airbox (the unit shown here is a hot-wire design). Air-flow meter engine management systems are sometimes known as MAF (mass air flow) systems. [Holden] largely the same in all cases. ECUs make decisions on the basis of the software that has been programmed into them. This software determines the correct fuelling at various engine loads (ie, the injector duty cycles) and the ignition timing – eg, for a particular engine load, it may decide on an injector duty cycle of 20% and to fire the spark plugs at 15° before Top Dead Centre. For the ECU to make these decisions, a lot of information about the engine’s operating conditions must be continually fed to it. This information is provided by various input sensors. The most important aspects of an engine’s operation that the ECU must have accurate and timely information on are: •  Engine load; Fig.8: the intake air temperature sensor is positioned on the airbox in this car. Other common locations for this sensor include on the intake manifold, where the sensor can then more accurately detect the effects of underbonnet heat-soak. [Mazda] •  Crankshaft rotational position; •  Engine temperature; and •  Air/fuel ratio Engine load is most often determined by an air-flow meter – a device that measures the mass of the air being drawn into the engine. If the ECU knows how much air is being drawn into the cylinders, then it can add the right amount of fuel to go with it. Air-flow meter-based systems are sometimes referred to as MAF (mass air flow) systems. Several different designs of air-flow meter are available: •  Hot-wire air-flow meters use a very thin, heated platinum wire. This wire is suspended in the intake air path or in a bypass passage and the temperature of the wire is electrically related to the mass of air passing it. Fig.9: knock sensors are usually firmly mounted on the engine block. They detect detonation and cause the ECU to retard the ignition timing. Most engines run ignition timing advance close to detonation, so the role played by this sensor is very important. [Ford] 10 PERFORMANCE ELECTRONICS FOR CARS Meters of this sort normally have a 0-5V analog output signal, although some have a frequency output. •  Vane air-flow meters employ a pivoting flap placed across the intake air path. As engine load increases, the flap is deflected to a greater and greater extent. The flap moves a potentiometer, which in turn alters the analog output voltage signal, which is typically 0-5V (although some meters use a 0-12V output range). •  Karman Vortex air-flow meters generate vortices whose frequencies are measured by an ultrasonic transducer and receiver. They use a flowstraightening grid plate at the intake to the meter. This type of meter has a variable frequency output. Of the three meter types, the hot-wire design is by far the most common on cars of the last decade, followed by the vane and then Karman Vortex – the latter used only by a few manufacturers (eg, Mitsubishi and Hyundai). The other way of measuring engine load is indirectly, by monitoring the manifold pressure. These systems are called MAP (manifold absolute pressure) systems. By measuring three factors – manifold pressure, engine RPM and intake air temperature – the ECU can estimate the mass of air flowing into the engine. Crankshaft (and often camshaft) position sensors tell the ECU where the crank is in its rotation. This is vital if the spark is to be fired at the right siliconchip.com.au time. In sequential injection engines, it is also used to time the injectors. The ECU can also calculate engine RPM from this sensor. Again, different sensor types exist: •  An optical position sensor uses a circular plate with slots cut into it. The plate is attached to the end of the camshaft and is spun past a LED. A sensor on the other side of the disc registers the light shining through the slots, with the ECU counting the light pulses. •  A Hall Effect position sensor uses a set of ferrous metal blades that pass between a permanent magnet and a sensing device. Each time a metal vane passes between the magnet and the Hall sensor, the Hall sensor switches off. •  An inductive position sensor reads from a toothed cog. It consists of a magnet and a coil of wire, and as a tooth of the cog passes, an output voltage pulse is induced in the coil. All these sensors have frequency outputs. Engine temperature is another important factor for the ECU, especially during cold starts. Two engine temperatures are usually monitored: coolant temperature and intake air temperature. Invariably, the sensors used here change their resistance with temperature. In operation, the sensor is fed with a regulated current from the ECU and the ECU then measures the voltage output from the sensor. Some cars use other temperature Fig.10: crankshaft position sensors can be of various designs and can be mounted either on the crankshaft or the camshaft. They detect piston position and are used to help determine ignition timing and injector timing (ie, in engines with sequential injection). [Ford] Fig.12: the oxygen sensor is mounted on the exhaust manifold and signals the real-time air/ fuel ratio to the ECU, to indicate whether the mixture is rich or lean. Most of the time, the ECU strives to keep the air/fuel ratio figure as close as possible to 14.7:1, to give the lowest possible emissions. [Holden] siliconchip.com.au Fig.11: a throttle position (TP) sensor is attached to one end of the throttle shaft. It monitors the opening angle of the throttle and produces a corresponding output voltage which is fed to the ECU. Older cars may use a throttle position switch, rather than a variable output sensor. [Holden] Fig.13: another Electronic Control Unit output is the idle speed control. A variable-size air bypass around the throttle body is used to regulate idle speed. In this design, the Idle Air Control (IAC) valve is operated by a variable duty cycle signal. [Ford] PERFORMANCE ELECTRONICS FOR CARS 11 How The ECU Calculates The Final Ignition Timing Fig.14: this diagram shows how an Electronic Control Unit goes about calculating the final ignition timing. The main inputs are from the top dead centre (TDC) sensor, crank angle sensor, air-flow sensor and vehicle speed sensor. If the engine is being cranked, the ignition timing is fixed at 5° of advance, as is also the case if an external connector is bridged and the idle timing is being adjusted. If neither of these conditions is occurring, the ignition timing is calculated primarily on the basis of engine speed and air flow. Additional corrections are then made from information received from the coolant temperature sensor, barometric pressure sensor and intake-air temperature sensor. A similar type of procedure is followed for fuel injector control. [Hyundai] Hot wire air-flow meters are the most common form of engine load sensing. They usually have a 0-5V output signal and this can be easily modified to alter mixtures and (to a degree) ignition timing. 12 PERFORMANCE ELECTRONICS FOR CARS sensors to measure fuel, cylinder head and exhaust gas temperatures. The oxygen sensor (sometimes called the EGO sensor) is located in the exhaust manifold. It measures how much oxygen there is in the exhaust compared with the atmosphere and by doing so, it indicates to the ECU whether the car is running rich or lean. This sensor generates its own voltage output, just like a battery. When the air/fuel ratio is lean, the sensor has a very low output; eg, 0.2V. Conversely, when the mixture is rich, the output voltage is higher; eg, 0.8V. Many cars now use multiple oxygen sensors; eg, before and after the catalytic converter(s). The ECU uses the output of the oxygen sensor(s) to keep the air/fuel ratio around 14.7:1 in cruise and idle conditions. To facilitate this, the sensor’s output voltage swings quickly from high to low (or low to high) as the mixture moves through the 14.7:1 (“stoichiometric”) ratio. Note that this means that the raw voltage output of the oxygen sensor is not directly proportional to the air/fuel ratio. A number of other sensors are also common to most engine management systems. For example, the throttle position sensor indicates to the ECU how far the throttle is open – see Fig.11. Most throttle position sensors use a variable potentiometer (or two) and have a 0-5V analog output. The vehicle speed sensor lets the ECU know how fast the car is travelling. This sensor can be mounted on the gearbox or in the speedometer and has a variable frequency output. Finally, the knock sensor works like a microphone that listens for the sounds of knocking (detonation). It’s screwed into the engine block and works with complex filtering and processing circuitry in the ECU to sense when knocking is occurring. Closed & Open Loop Two key operating conditions of the ECU need to be identified – “closed siliconchip.com.au loop” mode and “open loop” mode. “Closed loop” mode occurs when the air/fuel ratio is controlled primarily by the feedback from the oxygen sensor. In these conditions, the ECU is programmed to keep the air/fuel ratio close to 14.7:1 – the air/fuel ratio at which the catalytic converter works best at cleaning the exhaust gases. The oxygen sensor sends a voltage signal back to the ECU, indicating to the ECU whether the car is running rich or lean. If the engine is running a little rich, the ECU will lean it out. If it’s a little lean, the ECU will enrich the mixtures. The oxygen sensor then checks on the effect of the change. Closed loop running on most cars occurs primarily in cruise and idle conditions. In most cars, the oxygen sensor is ignored at full throttle – this is called open loop running. In this mode, the ECU bases its fuelling decisions totally on the information that has been programmed into it. If the ECU senses a high load, it will open the injectors for a relatively long time and spray in large amounts of fuel. Basically, the ECU uses a software table of information (called a map) that tells it how long to open the injectors at all the different engine loads. In addition to closed loop running, the oxygen sensor is also used as part of the ECU’s self-learning system, Instead of using an air-flow meter, some cars use a MAP sensor that measures manifold pressure. It’s either mounted directly on the intake manifold after the throttle butterfly (as here) or connected to the manifold by a rubber hose. where changes in the mixtures that would otherwise occur over time can be automatically corrected. Conclusion There are plenty of other inputs and outputs in engine management systems that haven’t been covered in this chapter – not to mention other system complexities in engine management systems. However, if you keep in mind that the ones covered here are the most important, you won’t  go far wrong. Fig.15: all engine management systems of the last decade control far more than just spark and fuel – and consequently also have many more inputs and outputs! This VT Commodore system works on a relatively simple supercharged V6 engine but has 18 inputs and 11 main outputs. By considering each of the inputs, you can get a good idea of the factors being taken into consideration by the Electronic Control Unit when it is making its decisions. [Holden] siliconchip.com.au PERFORMANCE ELECTRONICS FOR CARS 13