AFR Alarm

Who doesn’t like loud music and driving down an open highway?  When the car is already loud with louder music playing there is a good chance something bad could be happening without the driver noticing.  This will fix that.

AFR Alarm

How Does It Work

There are 8 lights for the lambda (air fuel ratio) sensor display, a button and 3 lights for the knock sensor display (optional).  The lambda lights to the left are richer, right are leaner.  The left green light should light up when the car is floored.  The right green light should be lit up under normal idling and most driving.  If I have the gas pedal down more than about 90% and the car is too lean, too rich or knocking, then it will mute the radio (using an external infrared LED not pictured above) and also sound a buzzer to bring it to my attention.  When that happens, the lambda or knock value where the problem happened will flash for about ten seconds while the current value of the sensor is still displayed.  Ten seconds later it will stop flashing and unmute the radio.  The LED’s for knock work with a GM ESC module (read how it works here).   The two red LED’s on the lambda meter will illuminate if the battery voltage is below 12.5 volts as well.  It has a button on the front of it to change modes through one of four modes: lights and sound all the time, only lights, lights and sound only when there is a problem, or never any lights or sound.  There is also an input for the interior lights that will dim the display when they turn on.

One other handy thing I wrote into the software is the ability to test the radio mute, throttle switching point, and buzzer while the car is off.  When the car is keyed on, and the engine is not running, if I slowly push down the gas pedal I can find the exact point at which the car is set to look for problems worth muting the radio for.  I will know because it will mute the radio and then sound the buzzer.  About ten seconds after letting off of the gas it will unmute the radio too.  After installing the device this is great to test that it will do everything that I hope will do.

AFR Alarm location

The depth of the button is specifically chosen so that it will be the only part protruding through the plexiglass gauge cover on the Fiero cluster.  It is also only a few millimeters beyond the face plate too.

What Else Can It Be Modified To Do

  • Lambda sensing could be programmed for narrow band sensor voltage range
  • Knock sensing is wired for easy modification for analog knock sensing like the 7730 uses
  • Knock sensing can be completely ignored if the input is grounded
  • A spare analog input is available at the harness connector
  • IR output for muting only supports Pioneer radios, but more can easily be added
  • IR output is not necessary and can simply not be plugged in to delete it
  • TPS sensor input (A1) does not have to be wired, no alarms will go off, ever

Installation

The inside of the cluster will have to be cut slightly because there is a divider down the center of the space where this installs.  Again the board was built specifically with the Fiero cluster dimensions in mind, so there is a little bit of gap all around.  The two large holes in the board can be used to secure the board to the cluster.  I found some small nylon screws that seem like a good fit so far.

Fiero cluster after cuttingAFR Alarm in cluster

 

 

 

 

The wires screw into the screw terminal at the back, before bolting it down.  The black metal plate in the cluster will need a slot cut in it.  Measure twice.  Cut once.  The plexiglass will only need a small hole drilled in it for the button to poke through.  Again, measure twice.

More Details

AFR_Alarm_BlkNWht_Numbered

  1. Harness connector
  2. Atmel processor
  3. Mounting hole
  4. LED’s for lambda display
  5. Mode select button
  6. LED’s for knock display
  7. Buzzer for alarm sounds and mode select
  8. Ceramic resonator with built in capacitors (crystal for processor)
  9. Voltage regulator
  10. Mounting hole
  11. In Circuit System Programmer (how to program the processor on the board)

Harness connector pins:

    • Dim: Interior light input to dim the LED’s slightly
    • Sp: Spare input, no use if you don’t modify the software
    • IR: Infrared LED output, connect to anode of LED, ground cathode
    • Kn: connected to signal output of ESC module
    • A2: Lambda sensor input (0-5 volt analog from LC-1)
    • A1: Throttle Position Sensor input (0-5 volt analog)
    • B+: Battery voltage (more than 7 volts)
    • -: Battery ground  (can be used to ground IR LED cathode and Kn pin)

Click here to download ExpressPCB circuit board design for AFR Alarm

Click here to view bill of materials with prices and op temps

Click here to download the Arduino source code 

AFR_Alarm_Schematic_1_0

Programming the chip can be done in a similar fashion to the Multigauge project of mine.  The chip can be programmed as it sits in the board using the Atmel AVRISP mkII, just so long as battery and ground are connected to harness connector.  With Arduino software installed, and the code for the project loaded, simply make sure the AVR ISP mkII is selected as the programmer.

Arduino-AVR1

Set the board type to Uno  in the menu, Tools -> Board -> Uno.  After that, press Ctrl+Shift+U to upload the software to the chip using the programmer, and give it a second.

Arduino-AVR2

If it works, you will know.  If it does not work, you will also know that.  If you want to learn more about how to use Arduino, then go here.  Chips can also be programmed in the Arduino Uno and then plugged into this board.  The chips used in the Uno end in part number “PU” instead of the “PN” that I used, but they are programmed the same.  To the best of my knowledge the only difference is that the PN part number has a wider operational temperature range, better for automotive use.

Leave a Reply