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":
Items relevant to "Duty Cycle Meter":
Items relevant to "High Temperature Digital Thermometer":
Items relevant to "Versatile Auto Timer":
Items relevant to "Simple Voltage Switch":
Items relevant to "Temperature Switch":
Items relevant to "Frequency Switch":
Items relevant to "Delta Throttle Timer":
Items relevant to "Digital Pulse Adjuster":
Items relevant to "LCD Hand Controller":
Items relevant to "Peak-Hold Injector Adaptor":
Items relevant to "Digital Fuel Adjuster":
Items relevant to "Speedo Corrector":
Items relevant to "Independent Electronic Boost Controller":
Items relevant to "Nitrous Fuel Controller":
Items relevant to "Intelligent Turbo Timer":
|
Chapter 9
Check your fuel injectors
with this:
The Digital Duty Cycle Meter uses a
2-digit LED display to show the realtime duty cycle of the injectors.
Duty Cycle Meter
Digitally monitor fuel injector duty cycles and also switch devices
on and off at different engine loads!
A
LL THE TIME that you’re driving
along, the fuel injectors under the
bonnet are rapidly clicking open and
shut – opening to allow fuel to squirt
into the ports behind the valves and
then closing until their next turn for
spraying action comes around. The
proportion of time that each injector
is open determines how much fuel gets
added to the intake air – ie, the injectors precisely meter the fuel.
This Digital Duty Cycle Meter allows you to actually see in real time
how long the injectors are open for. For
example, at idle they might be open
for only 2% of the time. Put your boot
into it and let the revs rise and you
might find that the injectors are open
for as much as 80% of the time! The
most that they can ever be open for is
100%, so if you’re driving a modified
car and the injector duty cycle (the
Specifications
Display resolution .................................................................................... 1%
Display range ....................................................... 0-99% (100% shown as "- -")
PWM display polarity ....................................... positive or negative selectable
Output switch threshold ............................................... adjustable from 1-99%
Output relay .........................................rated at 10A with NO and NC contacts
Output switch ........... triggered on rising or falling PWM percentage (selectable)
Hysteresis of switching .............................. adjustable in 1% steps from 0-99%
Maximum PWM input voltage ........................................................... 50V RMS
Maximum input frequency .........................10kHz (equivalent to 600,000 RPM)
Minimum input frequency ........................................................5Hz (300 RPM)
Display dimming ...................................... adjustable from full brightness to off
Supply voltage .............. 9V <at> 120mA (relay on) to 15VDC <at> 140mA (relay on)
50
PERFORMANCE ELECTRONICS FOR CARS
term for how long they’re open for)
is getting close to 100%, then larger
injectors (or an increase in fuel pressure) will be needed if you want even
more power.
As well as displaying injector duty
cycle, this meter also allows you to
turn things on and off on the basis of
duty cycle. In other words, it can act
as a sophisticated load switch. The
relationship between load and duty
cycle is very strong – much better
than using a boost pressure switch in a
turbo car to turn on a water spray or a
throttle microswitch to trigger nitrous
injection. You might want to turn on
water injection with a load equivalent
to 45% duty cycle, for example; or
perhaps an intercooler water spray
at 55% duty cycle.
At the other end of the scale,
perhaps you want to switch out an
electronic modification at very light
loads – eg, when there’s a duty cycle
of less than 5%.
This project allows you to monitor
the actual duty cycle of the injectors
and also allows you to switch devices
siliconchip.com.au
Fig.1: this shows where each of the components is placed on the main PC board. Use this diagram, the photos of the
completed board and the parts list to help you assemble it correctly.
Fig.2: this version has the two LED displays mounted on it, if you don’t want to use the external display board. Be sure to get
the orientation of the pushbutton switches correct.
on or off on the basis of load. It will
work equally effectively with factory
or aftermarket engine management.
Construction
Depending on how you choose to
build it, the Digital Duty Cycle Meter
will use two or three PC boards. One is
the main board, another is used if the
digital display is mounted remotely
and the third is for the PWM generator. This last board is a pulse generator
with a variable duty cycle so that it’s
easy to test that the Digital Duty Cycle
Meter is working correctly.
When assembling the main PC
board, follow the overlay diagram and
photos closely. Make sure that the
pushbutton switches are orientated
with the flat side as shown and be careful to get the polarised components the
siliconchip.com.au
Follow this photo and the parts
overlay diagrams when constructing the
main PC board. If you are a beginner, it’s
easier to mount the LED displays on this
main board rather than remotely.
PERFORMANCE ELECTRONICS FOR CARS
51
How It Works
The circuit for the Duty Cycle Meter
is based on microcontroller IC1 which
monitors the pulse signal applied to fuel
injector solenoids, etc. It displays the
duty cycle as a percentage.
In operation, the unit measures the
time between two positive edges of
the pulse waveform and also the time
from the positive edge to the negative
edge. Through a series of calculations,
these measurements are converted to
a percentage which is shown on the
2-digit display.
The meter can display the percentage duty cycle for positive referenced
signals or for ground referenced
signals. All this means is that positive
referenced signals have a 0% duty cycle
that when the signal is always positive
and a 100% duty cycle when the signal
is always at ground. This type of signal
is normal for fuel injectors which are
switched to ground to open them.
Conversely, ground referenced signals
have 0% duty cycle when the signal is
continuously at 0V (ie, off) and 100%
duty cycle when the signal is fully on.
The pulse signal is applied to pin 6
of IC1 via a network consisting of two
10kΩ resistors, zener diode ZD2 and
a 1nF capacitor. Internal to pin 6 is a
Schmitt trigger which ensures a clean
signal for measurement.
The display segments are driven
The PWM Generator is included to allow the Duty Cycle Meter to be tested.
It uses a 7555 timer (IC1) which charges and discharges a 100nF capacitor
connected to pins 2 and 6 via trimpot VR1 and diodes D2 & D3.
When the VR1’s’ wiper is close to D3, the 100nF capacitor charges quickly
and discharges slowly, giving a pulse train output at pin 3 with a short high
duration and a long low period; ie, low duty cycle. Alternatively, when VR1’s
wiper is close to D2, the 100nF capacitor charges slowly through D3 for a long
high output and discharges quickly through D2 for a short low output time; ie,
high duty cycle. Thus VR1 allows the duty cycle to be adjusted from 1% to 99%.
Fig.3: this shows where each of the parts
is placed on the PWM generator test
module. Use this diagram, the two photos
and the parts list to help you assemble it
correctly.
52
PERFORMANCE ELECTRONICS FOR CARS
from IC1’s RB1-RB7 and RA0 outputs via
150Ω current limiting resistors. The displays are multiplexed, with each digit’s
common anode driven separately via a
transistor (Q1 and Q2). Q1 is switched
on when the RA3 output goes low and
so DISP1’s display segments are driven
by RB1-RB7 and RA0. Similarly, transistor Q2 is turned on when RA2 is low to
drive DISP2. The displays are driven
alternately at a fast rate so that they
appear to be continuously lit.
Dimming is achieved using LDR1, op
amp IC2 and transistor Q3. In bright
light, the LDR is a low resistance and
so pin 3 of IC2 is held close to +5V.
This turns Q3 fully on to supply full
current to the emitters of Q1 and Q2.
This allows the displays to operate at
full brightness.
If the ambient light drops to a low
level, the resistance of LDR1 increases
and the voltage at pin 3 of IC2 falls. The
lower voltage at pin 3 is reproduced
by Q3 and the display is dimmed.
Trimpot VR1 sets the brightness of
the display.
Switches S1-S3 are monitored via
RA4 (pin 3). This pin is normally held
high via a 10kΩ pull-up resistor. When
this input is pulled low, it means that
one of the switches has been pressed.
The program inside IC1 decides which
of the three switches has been pressed
by checking if the RA2 and RA3 outputs
are low or not.
Output RA1 (pin 18) drives transistor Q5 which in turn drives the relay
connected to the 12V supply. When
the relay is powered, the common (C)
and the normally open (NO) contacts
are closed. When the relay is off, the
common and normally closed (NC)
contacts are closed.
Transistor Q4 performs a power-on
reset for IC1 to ensure that pin 4 is
right way around. Use an IC socket
for IC1 and remember that both ICs
must be orientated correctly.
As indicated above, the LED displays can be remotely mounted on
a separate display PC board and
connected to 5-way pin headers on
the main board using rainbow cable.
Alternatively, the displays can be
siliconchip.com.au
Fig.4: this is the circuit for the Duty Cycle Meter. It’s based on a specially programmed
PIC16F84-20P microcontroller (IC1) driving two 7-segment LED displays.
only switched high when the supply is
above about 3.5V. For voltages below
this, the microcontroller is held in the
reset state (ie, quiescent).
IC1 is operated at 10MHz using crys-
tal X1. This enables the program within
IC1 to perform fast measurements of
the duty cycle at up to 10kHz.
Power for the circuit comes via diode
D1 which provides reverse polarity pro-
mounted directly on the main PC
board in the holes provided. If you
use the remote-mount option, be sure
to install the wire link on the display
PC board between DISP1 and DISP2,
before actually mounting the displays
in place – see Fig.5.
The LDR (which controls the
auto-dimming function) can also be
mounted on long leads – alternatively,
drill a hole in the box to allow ambient
light to shine on the LDR.
The test PWM generator has only a
handful of components but be careful
with those that are polarised.
siliconchip.com.au
Testing
Connect the output of the test PWM
tection. IC1 is powered from +5V which
is derived from REG1, an LM2940CT-5
regulator designed specifically for automotive applications. The 10Ω resistor
and 100µF capacitor at REG1’s input
provide a degree of transient voltage
suppression. Zener diode ZD1 protects
IC2 from voltage spikes.
generator to the Digital Duty Cycle
meter input. Using a 12V power supply or the car battery, apply power to
both the Digital Duty Cycle Meter and
the test PWM generator. The display
should spring into life and as the
trimpot on the generator is rotated,
the numbers on the display should
also change.
PERFORMANCE ELECTRONICS FOR CARS
53
Parts List
1 main PC board, code 05car021,
122 x 61mm
1 display PC board, code 05car022,
30 x 28mm
1 plastic case, 130 x 68 x 44mm
(Jaycar Cat. HB6014 – optional;
not supplied with kit)
1 28 x 28 x 2mm red transparent
Perspex or Acrylic sheet
1 12V 5A relay with DPDT contacts
(Jaycar Cat. SY4052; Relay 1)
1 DIP18 IC socket for IC1
2 5-way (or 6-way) pin headers
2 5-way (or 6-way) header sockets
(CON1, CON2)
1 LDR (Jaycar Cat. RD3480 or
equivalent) (LDR1)
1 10MHz parallel resonant crystal (X1)
1 500kΩ horizontal trimpot (VR1)
6 6.3mm PC-mount spade connectors with 5mm pin spacing
5 6.3mm female spade connectors
3 click-action pushbutton switches
(S1-S3)
2 M3 x 6mm tapped standoffs
2 M3 x 6mm countersunk screws
2 M3 x 6mm machine screws
2 3mm washers
2 1.5m lengths 5-way rainbow cable
1 2m length of heavy-duty red
hookup wire
1 2m length of heavy-duty green
hookup wire
1 2m length of heavy-duty black
hookup wire
1 150mm length of 0.8mm tinned
copper wire
Semiconductors
1 PIC16F84A-20/P microcontroller
programmed with dutycycl.hex (IC1)
1 LM358 dual op amp (IC2)
1 LM2940CT-5 low dropout
automotive regulator (REG1)
2 common anode displays (DISP1,
DISP2) (Jaycar Cat. ZD1857)
3 BC327 PNP transistors (Q1-Q2, Q4)
It’s important to have the system
working before you install it in the
car. If there are problems, switch off
immediately and inspect the board
very closely, looking for solder bridges
between tracks, dry joints or components either in the wrong way around
or in the wrong place entirely.
When everything appears to be
54
PERFORMANCE ELECTRONICS FOR CARS
RESISTOR COLOUR CODES
Value
4-Band Code (1%)
5-Band Code (1%)
220kΩ
39kΩ
22kΩ
10kΩ
2.2kΩ
680Ω
150Ω
10Ω
red red yellow brown
orange white orange brown
red red orange brown
brown black orange brown
red red red brown
blue grey brown brown
brown green brown brown
brown black black brown
red red black orange brown
orange white black red brown
red red black red brown
brown black black red brown
red red black brown brown
blue grey black black brown
brown green black black brown
brown black black gold brown
2 BC337 NPN transistors (Q3, Q5)
2 1N4004 1A diodes (D1, D2)
2 16V 1W zener diodes (ZD1, ZD2)
Capacitors
1 100µF 16V PC electrolytic
3 10µF 16V PC electrolytic
1 100nF MKT polyester (code 104
or 100n)
1 1nF MKT polyester (code 102 or 1n)
2 22pF ceramic (code 22 or 22p)
Resistors (0.25W 1%)
1 220kΩ
1 39kΩ
1 22kΩ
5 10kΩ
1 2.2kΩ
2 680Ω
8 150Ω
1 10Ω
PWM Generator
1 PWM generator PC board, code
05car023, 40 x 28mm
1 500kΩ horizontal trimpot (VR1)
3 6.3mm PC-mount spade
connectors with 5mm pin spacing
3 6.3mm female spade connectors
1 2.2kΩ resistor (0.25W, 1%)
Semiconductors
1 7555 CMOS 555 timer (IC1)
1 1N4004 1A diode (D1)
2 1N4148 diodes (D2,D3)
Capacitors
1 470µF 16V PC electrolytic
2 100nF MKT polyester (code 104
or 100n)
working correctly, use the pushbuttons
to try out the various functions of the
meter.
The meter is initially set having a
ground-referenced reading so that a
high voltage (eg, +12V) will show 100%
and a ground voltage (0V) at the input
will show 0%. The relay output is set
so that it will switch on when the duty
cycle exceeds 50%. It will switch off
when the duty cycle drops below 45%;
ie, the hysteresis is set at 5%.
To change these settings, press
the Mode switch and the display will
show “P.”. The “P” stands for polarity
and can be changed by pressing the
up or down switch so that the display
shows “P.-”. This setting means that
the display will show 0% when the
input is high and 100% when the input is at ground. The polarity setting
switches between a “P.” and “P.-” at a
0.5-second rate while one of the Up
or Down switches is pressed. If, when
connected to the idling car, the display
shows (say) 98% instead of 2%, alter
the polarity with this function.
The remaining mode functions are
for the relay output switching. Pressing the Mode switch again will show a
“d.H” on the display which means that
the relay will switch on when the set
duty cycle is exceeded. Pressing the Up
or Down switch will toggle the display
to the “d.L” setting which means that
the relay will be switched on for duty
cycles below 50% and will be off for
duty cycles above 55%. This 55% off
setting is due to the 5% hysteresis.
The next pressing of the Mode
switch will show “50.”. This is the
relay switching threshold setting. It
can be changed by pressing the Up or
Down switches. Press the Up switch
to increase the setting and the Down
switch to decrease the setting. The
next pressing of the Mode switch will
show the Hysteresis setting which is
initially 5. It can also be changed using
the Up and Down switches.
Now press the Mode switch again
and the display will return to showing
duty cycle as normal. Any changed
settings will be permanent unless
changes are made again to the alternate settings or values. Pressing the
siliconchip.com.au
Mode switch to cycle through the settings will not alter the values.
Adjust trimpot VR1 so that the display brightness is sufficiently dimmed
in darkness – set it clockwise for
maximum display brightness.
Fitting
Fitting the Digital Duty Cycle Meter
is straightforward – at its simplest,
only three wiring connections need to
be made. These are: ignition-switched
+12V power, earth and an injector
connection. This wiring is most easily performed at the ECU. No harm
will come from connecting the input
signal directly to +12V or earth, so
don’t panic if you first back-probe the
wrong ECU pin.
The relay can be used to control
external loads (up to 5A). It has three
terminals: common, normally-open
(NO) and normally-closed (NC). If
you want to switch an intercooler
water spray pump, for example, feed
ignition-switched +12V to the common
terminal and wire the pump between
Peak/Hold Injectors?
Some cars are fitted with what are
known as “peak-hold” fuel injectors
instead of conventional fuel injectors. You can still measure the duty
cycle of this type of injector but, in
this case, you have to connect the
Duty Cycle Meter via the Peak-Hold
Adapter described in Chapter 18.
What are peak-hold injectors and
how do you know if your car has
them? Chapter 18 has the details.
Fig.5: here’s how to assemble the display
board. Make sure that the displays are
orientated correctly, with the decimal
point at the bottom. A piece of transparent
red acrylic makes the LED displays more
visible, as shown at right.
the normally-open relay terminal
and ground. That way, the pump will
switch on whenever the designated
duty cycle is exceeded (assuming that
you have the Digital Duty Cycle Meter
set to dH mode, of course).
Devices that you can control with
the relay include:
(1). A “high duty cycle” warning light
or buzzer (eg, operates at 90% and
higher duty cycles, switches off at
85%).
(2). An intercooler water spray (eg, operates at 50% and higher duty cycles,
switches off at 45% – ie, operates at
high loads).
(3). An intercooler cooling fan (eg,
operates at duty cycles of less than
2%, switches off at 5% – that is, operates only at idle or very slow speeds,
although note that it will also trigger
during injector over-run shut-off).
(4). An engine management modification (eg, switches in modification only
at loads above say 50% duty cycle,
switches out modification at 45%).
(5). An extra fuel pump (eg, switches
in additional pump above say 50%
duty cycle, switches out additional
pump at 45%).
Because the relay can be triggered
with either a rising or falling duty
Fig.6: this diagram shows how ribbon cable is used to connect the main and remote display PC boards together.
siliconchip.com.au
PERFORMANCE ELECTRONICS FOR CARS
55
Here the PWM generator has been connected to the Digital
Duty Cycle Meter – it’s as easy as connecting the “OUT”
terminal of the PWM generator to the “INPUT” terminal of
the Digital Duty Cycle Meter, and making power and earth
connections to both PC boards.
Finished with the PWM Generator?
After you’ve built and installed the
Digital Duty Cycle Meter, you’ll have one
PWM generator that’s surplus to requirements. But with just a few component
changes you can turn this into a high
performance LED flasher.
At its simplest, all that you need
to do is replace the 100nF capacitor
near the output terminal with a different
capacitor and then wire a LED between
the output terminal and earth (with the
long LED lead to the output terminal).
The value of capacitor that is used will
determine the flash rate, while the duty
cycle (the relative length of on and off
times) and LED brightness can still be
altered by the pot.
If you use a 2.2µF electrolytic capacitor (negative closest to the edge of
the PC board), the LED will flash around
56
PERFORMANCE ELECTRONICS FOR CARS
once per second. This is an ideal flash
rate for a car alarm indication and the
beauty is that you can adjust the pot
to make the “on” time very short, just
as factory alarm LEDs operate.
This also reduces the current draw
enormously. Use a high-intensity LED
together with the current limiting resistor already in the circuit and you could
expect the LED to flash for literally
weeks without flattening the car battery. Halve the capacitance and the
flash rate will double – 1µF is excellent
if you need a bit more urgency to your
alarm flashing.
Alternatively, a 470nF MKT polyester
capacitor and suitably tweaking the
duty cycle pot setting will give a fast
flash – ideal as a dashboard warning or
for a really attention-getting shift-light.
cycle and because the hysteresis (the
difference between switch-on and
switch off values) is also adjustable,
the switching side of the Digital Duty
Cycle meter is very useful.
In Use
When first powered up, the display
will stay blank for a moment or two,
before settling at “0”. Start the car
and the display will show a very small
number – perhaps 1 or 2%. This is
because at idle, the injectors are open
for only a very small proportion of the
available time. Blip the throttle and
the number will race up.
When you take the car for a drive
you’ll notice that if you lift off the
throttle at high revs, the display
will show ‘0’. This is because on the
over-run, the injectors are shut off
completely to save fuel. If your car’s
injectors are being pushed so hard that
sometimes they’re continuously open,
siliconchip.com.au
Remote Mounting
the Display
The 2-digit LED display can be
mounted either directly on the main
PC board (Fig.2) or remotely, with
the connection to the main board
made via ribbon cable. We chose this
“remote mounting” approach, placing
the display in a housing that was then
positioned inside a second glovebox.
The housing was made from a small
diameter plastic pipe blanking cap. A
holesaw was used to make a hole in
the end of the cap and then progressively finer sandpaper used to smooth
and shape the resulting flange formed
around the opening. A separate piece
of plastic was cut to form the rear panel
of the enclosure.
The lens was made from smoked
grey translucent plastic, salvaged from
an old VCR. This was shaped into a disc
that dropped into the flange from the
rear of the holder. The lens was then
masked from inside using four short,
straight pieces of electrical tape, stuck
to the back of the lens and creating a
rectangular window for the LEDs to
show through.
A thin piece of clear orange-red
acrylic was also placed between the
LED display and the lens. Finally, the
holder was spray painted black and
mounted in place.
When selecting the mounting location, keep in mind that the LED display
– even behind grey plastic – won’t be
able to be read with direct sunlight falling on it. Try to position it so that the
display is shaded in most conditions.
Portable Instrument
To get more power out of your engine, you need to add more fuel. Whether or not the
injectors can keep up with the new demands made on them will depend on what duty
cycle they’re running – once they reach 100%, they’re fully open. This meter displays the
real-time duty cycle of the injectors, so you can see how much latitude you’ve got left.
the display will show “--”, meaning
100% has been reached.
Other Uses
While we have concentrated on
measuring injector duty cycle, there
are other automotive devices which
are controlled with varying duty cycles. These include turbo boost control
siliconchip.com.au
solenoids, power steering flow control
solenoids and automatic transmission
flow and pressure control solenoids.
The Digital Duty Cycle Meter can
be used to display these duty cycles as
well, allowing you to see (for example)
the control behaviour of the factory
boost solenoid. This information is
very useful if you are modifying the
The Digital Duty Cycle Meter will
work from a 9V battery, allowing the
unit to be mounted in a box and used
as a portable diagnostic tool.
In this form, the PC board must be
mounted so that the mode switches
are accessible and the LED display is
visible. You would also need to add
a power switch. The relay could be
used to trigger an inbuilt buzzer, with
the trip threshold set depending on
the application (eg, as an “injector
duty cycle too high” warning).
To connect the instrument to the
car, you’ll need to make only the
earth and injector connections under
the bonnet.
system. In addition, you can use the
relay to switch devices on the basis of
these measured duty cycles.
Conclusion
Whether it is built to monitor injector opening percentages or to switch
loads, the Digital Duty Cycle Meter is
a useful and effective tool.
PERFORMANCE ELECTRONICS FOR CARS
57
|