Silicon ChipFrequency Switch - 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 14 Frequency Switch A cheap, adjustable design that lets you switch devices on and off according to speed T HERE ARE MANY automotive performance applications where you want to turn something on or off on the basis of road or engine speed. A shift light is a good example – you want a high intensity LED to illuminate just before the red-line, to warn you that it’s time to snatch the next gear. Or maybe you want a variablelength intake manifold to change from long to short runners at non-standard revs. Or perhaps you want to operate a device on the basis of road speed – eg, switch on an intercooler fan when the car is moving only slowly or sound an over-speed warning when you’re going too fast, for example. This Frequency Switch can do all of those things – and more. It also has adjustable hysteresis (that’s the difference between the switch-on and switch-off frequencies) and comes with both a LED and a relay. The relay is there so that you can switch big loads, while the LED can be mounted on the dash so that you can see the switch operation. Alternatively, the LED could be used purely as an indicator – eg, as an over-speed warning or as a shift light. Construction The Frequency Switch is a simple kit to build but you should make one decision before you start work. Will you be using it to detect a frequency that is rising to the trip point or falling to the trip point? The unit can be configured to work with either type of signal but if you know which way you’re going, you won’t have to make changes later on. The detection of a rising frequency will be the more common application – for example, triggering a shift-light when engine revs reach a high speed. Main Features •  Adjustable switching level be- tween 10Hz and 500Hz input •  Dual double-pole changeover 5A relay contacts •  Switches on rising or falling frequency The Frequency Switch can be used to trigger a shift light or buzzer – an indication that engine revs are getting close to the red-line and it’s time to change up a gear. 82 PERFORMANCE ELECTRONICS FOR CARS •  Adjustable hysteresis •  Easy to build siliconchip.com.au However, if you want something switched as frequency decreases to a certain level – for example turning on an intercooler fan when the car is travelling slowly – then you’d configure the Frequency Switch to detect a falling frequency. So what are the changes made for the differing configurations? They’re simple: for a rising frequency (low to high) detection, link LK1 is placed in the (L/H) position (that is, closest to the top of the PC board when the board is orientated as shown in Fig.1). For detection of a falling frequency (high to low), link LK1 is moved to the H/L position. Note that the Frequency Switch in the photos is configured to switch on a falling frequency (H/L), while the parts overlay diagram (Fig.1) shows the PC board configured to switch on a rising frequency (L/H). When assembling the PC board, make sure that you insert the polarised components the correct way around. The diodes, IC, LED, transistors, voltage regulator and electrolytic capacitors are the easiest to make mistakes with. During construction look at the photos and overlay diagram closely to avoid making mistakes. Fig.1: use this diagram and the photos of the completed project when assembling the PC board. Take particular care with the components that are polarised – for example, the diodes, IC and electrolytic capacitors. Set-Up & Fitting The Frequency Switch can be set to two broad frequency ranges: 10-100Hz or 50-500Hz. If measuring engine RPM, this corresponds to 600-6000 RPM for the first range or 300-30,000 RPM for the second range. To set the required range, connect +12V and ground and then measure the voltage between TP1 and ground. Adjust VR2 for 1.5V if you want the first frequency range or to 6V if you want the second range. In most applications, the first (ie, lower) range will be required. That done, you can install the unit in the car. In addition to providing power (switched +12V ignition supply) and earth connections, you will need to tap into the frequency signal that you want to monitor and connect this signal to the input terminal. This signal wire can be from the: •  Road speed sensor •  ECU tacho output •  Switching side of an injector •  Crankshaft or camshaft position output sensor At this stage, don’t connect anything to the relay – you will be able siliconchip.com.au The Frequency Switch is a multi-purpose building block that can be used to operate a shift light, alter intake manifold runner length, turn on intercooler fans at low road speeds – and a host of other uses. Both LED and relay outputs are provided. RESISTOR COLOUR CODES Value 4-Band Code (1%) 5-Band Code (1%) 100kΩ 10kΩ 3.3kΩ 1.8kΩ 1kΩ 100Ω 10Ω brown black yellow brown brown black orange brown orange orange red brown brown grey red brown brown black red brown brown black brown brown brown black black brown brown black black orange brown brown black black red brown orange orange black brown brown brown grey black brown brown brown black black brown brown brown black black black brown brown black black gold brown to see when the relay clicks over as the LED will light (and in quiet environments you’ll also hear the relay change over). So how do you set the trip point? You might want to have the Frequency Switch trigger a shift-light at 6000 RPM. But you don’t have to start off holding the engine at six grand – instead, adjust VR1 until the LED comes PERFORMANCE ELECTRONICS FOR CARS 83 How It Works The frequency input signal is applied to a 10kΩ resistor and then to zener diode ZD1 which limits the signal to between +16V and -0.6V. The 10nF capacitor filters the signal, removing high-frequency noise. The signal is then applied to pin 1 of IC1 via another 10kΩ limiting resistor. IC1 is a frequency-to-voltage converter. The pin 1 input signal is compared with the voltage at pin 11 which is set at about +1.8V using 10kΩ and 3.3kΩ voltage divider resistors across the 7.4V supply. A comparator within IC1 will provide an output signal if the signal level at pin 1 swings above the 1.8V threshold for pin 11. This internal comparator drives a frequency-to-voltage converter which Suggested Uses •  Operate a shift-light at set revs •  Operate changeover inlet manifolds •  Operate an intercooler fan at low road speeds •  Over-speed warning •  Control active spoilers •  Auto trans over-drive lock-out 84 PERFORMANCE ELECTRONICS FOR CARS charges the capacitor at pin 2 and then transfers this charge to the capacitor at pin 4. Trimpot VR1 adjusts the voltage developed at pin 3 with respect to the input frequency. This voltage is monitored by another internal comparator which has its inputs at pins 4 and 10. Pin 10 monitors the voltage set by trimpot VR2 (Threshold). The output at pin 8 will be high (+7.4V) when pin 4 is below pin 10. If pin 4 goes above pin 10, pin 8 will go low (0V). Hysteresis is included by virtue of the series 100Ω resistor, trimpot VR3 and diode D3. Hysteresis prevents the output from oscillating when the signal is just at the threshold point. The pin 8 output from IC1 drives transistors Q1 and Q2. Either one of these transistors can be selected to drive the relay, depending on the setting of link LK1. When LK1 is in the H/L position, Q1 drives the relay and when LK1 is in the L/H position, on at (say) 3000 RPM and then goes off as revs again drop. By adjusting the hysteresis pot (VR3), you should be able to alter how much the engine speed drops before the LED turns off. (Hint: if the LED flashes on and off around the switch-off point, increase the hysteresis by turning VR3 anticlockwise.) Q2 drives the relay. This enables the relay to switch when the input changes from a high-frequency signal to a lowfrequency signal (LK1 in position H/L), or when the input changes from a low frequency to a high frequency (LK1 in position L/H). LED1 lights whenever the relay is energised. Power Supply Power is obtained from the switched +12V ignition supply. Diode D1 gives reverse connection protection, while the 10Ω resistor, 100µF capacitor and zener diode ZD1 provide transient protection for regulator REG1. All the circuitry is powered from REG1 via D2, except for the relay and LED1 which are driven from the +12V supply. D2 is included to reduce the 8V from the regulator to about 7.4V which is necessary for correct operation of IC1 (it prevents an internal power supply zener diode in IC1 from conducting). With the system working as it should, turn trimpot VR1 a little more anti-clockwise to increase the trip-point frequency and then blip the engine until it again switches on the LED. By making changes to VR1 and then assessing the results with blips of the throttle, you should be able to quickly and easily set the trip point siliconchip.com.au Parts List Fig.3: the relay on the Frequency Switch can be used to turn on large loads. For example, as shown here, a high power shift light can be wired into place. 1 PC board coded 05car051, 105 x 60mm 1 plastic case, 130 x 68 x 42mm (optional – not in kit) 5 PC mount 2-way screw terminals with 5mm pin spacing 1 12V PC mount DPDT 5A relay (Relay1) 1 3-way header with 2.54mm spacing 1 jumper shunt with 2.54mm spacing 1 1MΩ horizontal trimpot (VR1) 1 2kΩ multi-turn top adjust trimpot (VR2) 1 10kΩ horizontal trimpot (VR3) Semiconductors 1 LM2917 frequency-to-voltage converter (IC1) 1 7808 3-terminal regulator (REG1) 2 BC337 NPN transistors (Q1,Q2) 1 5mm red LED (LED1) 2 16V 1W zener diodes (ZD1,ZD2) 3 1N4004 1A diodes (D1,D2,D4) 1 1N4148 switching diode (D3) Capacitors 2 100µF 16V PC electrolytic 2 10µF 16V PC electrolytic 1 1µF 16V PC electrolytic 1 22nF MKT polyester (code 223 or 22n) 1 10nF MKT polyester (code 103 or 10n) Resistors (0.25W, 1%) On modified engines with changeover intake manifolds, the frequency switch can be used to set the revs at which the runners swap from long to short length. at the correct engine revs. Note that VR1 is a multi-turn pot. This has been used so that the trip point can be adjusted very precisely – however, if you’re not used to this type of pot, be aware that you can keep on turning it endlessly and never reach a clear “stop”! In the above example, you’ll probably want only a small hysteresis (ie, a small difference between the switchon and switch-off frequencies). But in some cases, a much larger hysteresis works very well. For example, if you use the Frequency Switch to turn on an intercooler fan at low road speeds, the adjustable hysteresis can be used to keep the fan siliconchip.com.au running until you’re again travelling fast enough to push air through the core. In this case, you could set the turn-on at 10km/h and then adjust the hysteresis so the fan doesn’t turn off until 35km/h. This works well in practice where heat-soak of the intercooler is more likely to have been occurring after you’ve been stopped for awhile and are driving off slowly. The device that is to be triggered by the relay will normally be switched via the Normally Open (NO) and Common (C) relay contacts. Fig.3 shows these connections. Note that because a double-pole, double-throw (DPDT) relay has been used, another completely in- 1 100kΩ 7 10kΩ 1 3.3kΩ 1 1.8kΩ 2 1kΩ 1 100Ω 1 10Ω dependent circuit can also be switched simultaneously. This other circuit can even turn off the second device as the first is switched on. Note that if you just want to simply monitor a frequency (eg, engine revs), you can delete the relay and just mount the LED on the dashboard instead. In most applications, once the Frequency Switch is set, it won’t need to be altered again. The PC board fits straight into a 130 x 68 x 42mm jiffy box, so when the system is working correctly, it can be tucked out of  sight. PERFORMANCE ELECTRONICS FOR CARS 85