g-Sensor High-Brightness LED Brake Lamp

Freescale Semiconductor
Application Note
Document Number: AN3380
Rev. 0, 12/2006
g-Sensor High-Brightness LED
Brake Lamp
by: Matt Ruff and Wolfgang Bihlmayr
Automotive Systems Engineering
Austin, Texas and Munich, Germany
The g-sensor high brightness LED brake lamp
application is designed with motorcyclist safety in mind.
Although the principles transfer to any vehicle, they are
especially valuable to drivers on two wheels.
Motorcyclists are hard to see in traffic, and most
accelerate and decelerate faster than cars. These
combined factors increase the chances for motorcyclist
injury and fatality.
The g-sensor brake lamp provides high-intensity variable
light output proportional to a vehicle’s deceleration,
providing valuable information to drivers behind
motorcycles. The brake lamp uses the MMA7260Q three
axis, low-g accelerometer and the highly integrated
Freescale MM908E625 system in a package device
containing an HC908EY16 microcontroller and fully
self-protecting and intelligent analog circuitry. The
HC908EY16 reads three axes of acceleration and
deceleration data from the accelerometer, controls the
system, and drives eight high-brightness LEDs.
© Freescale Semiconductor, Inc., 2006. All rights reserved.
Contents
1
Basic System Description . . . . . . . . . . . . . . . . . . . . . . . . 2
1.1 Key System Features . . . . . . . . . . . . . . . . . . . . . . . 2
1.2 System Block Diagram . . . . . . . . . . . . . . . . . . . . . . 2
1.3 Basic System Behavior . . . . . . . . . . . . . . . . . . . . . . 4
2
Accelerometers: The Key to the System . . . . . . . . . . . . . 5
2.1 Measuring Deceleration with the MMA7260Q . . . . . 5
2.2 Collecting Acceleration/Deceleration Data . . . . . . . 6
2.3 Managing Vibration and Noise . . . . . . . . . . . . . . . . 8
3
Driving the High Brightness LEDs . . . . . . . . . . . . . . . . . 10
3.1 Basic HBLED Drive Channels with MM908E625
Half-Bridges. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
3.2 Additional LED Control Circuitry . . . . . . . . . . . . . . 12
4
Additional System Features. . . . . . . . . . . . . . . . . . . . . . 12
5
Software Design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
5.1 Software State Machine . . . . . . . . . . . . . . . . . . . . 13
5.2 Accelerometer Initialization and Calibration . . . . . 14
6
Looking Forward . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
7
References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
8
Schematics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
8.1 Bill of Materials . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
Basic System Description
1
Basic System Description
1.1
Key System Features
The g-sensor brake lamp is a brake lamp with light output proportional to the vehicle’s deceleration. The
brake lamp has many functions beyond a proportional brake light:
• High brightness LED output with eight, one-watt high-brightness LEDs (approximately 350 lumen
maximum light output)
• Four brake-intensity warning levels based on deceleration
• Redundant backup for standard brake lamp for added safety
• Self-calibration-capable — Automatically senses physical mounting orientation and re-calibrates
• Photo-sensor that compensates for brightness output in daylight or night-light
• Flashing turn signal duplication
• White LED outputs illuminate license plate
• LIN network communications
1.2
System Block Diagram
Figure 1 shows a block diagram of the g-sensor brake-lamp design. Internal components of the
MM908E625 device are shown separately for clarification but are contained in a single package. This
package contains the MCU and analog circuitry to drive the high-brightness LEDs, monitor the g-sensor
output, the brake, left turn, and right turn signal lamps, as well as communicate over the LIN network.
Figure 1. Block Diagram of g-Sensor Brake Lamp
g-Sensor High-Brightness LED Brake Lamp, Rev. 0
2
Freescale Semiconductor
Basic System Description
Figure 2 shows both sides of the circuit board. The board layout allows for spacing of the HBLEDs for
heat dissipation and for visual separation when mounted to a vehicle. The LEDs are mounted on one side
of the board designed to mount into a bezel with holes cut for the LEDs. All other components are mounted
to the other side of the board.
Figure 2. g-Sensor Brake Lamp Hardware — Front and Back of PCB (Revision 2)
Basic design components:
• The MCU reads the information from the accelerometer, interprets it, decides what the required
LED output should be, and communicates this to the analog half-bridge outputs and timer channels
to display.
• The accelerometer measures the acceleration of the assembly in all three axes. This allows the unit
to be self calibrating by measuring the force of gravity when the unit at rest.
• The half-bridge-drive circuits in the analog portion of the MM908E625 device are used to provide
current for the HBLEDs.
• A photo sensor measures ambient light levels and provides a variable resistance the MCU uses to
determine the light level in the environment and adjusts the HBLEDs’ brightness. In this way, the
light output of the HBLEDs reduces at night and increases during the day to maximize visibility.
Figure 3 shows the component layout with an earlier revision of hardware.
g-Sensor High-Brightness LED Brake Lamp, Rev. 0
Freescale Semiconductor
3
Basic System Description
Figure 3. Layout of g-Sensor Brake Lamp Components
1.3
Basic System Behavior
The g-sensor brake lamp provides a variable brake lamp output based on deceleration. Figure 4 and
Figure 5 show normal- and maximum-effort braking scenarios. Figure 4 shows the brake lamp in action,
with speed and deceleration shown on gauges. Maximum-effort braking occurs because a car pulled out in
front of the rider. Notice the deceleration is much greater, as indicated by the gauge and the unloading of
the bike’s rear suspension. The g-sensor brake lamp (below the standard brake light) responds by lighting
more LEDs.
.
Figure 4. g-Sensor Brake Lamp Output-Simulation Comparison
Figure 5 shows the actual g-sensor brake lamp prototype hardware on a test track. The g-sensor brake lamp
is mounted to the motorcycle’s top luggage case, above the standard brake lamp. In the normal braking
picture, four LEDs are illuminated. In the maximum effort braking picture, all eight LEDs are illuminated,
indicating a much higher level of deceleration.
g-Sensor High-Brightness LED Brake Lamp, Rev. 0
4
Freescale Semiconductor
Accelerometers: The Key to the System
Figure 5. g-Sensor Brake Lamp Output Comparison
2
Accelerometers: The Key to the System
2.1
Measuring Deceleration with the MMA7260Q
The heart of the system is the MMA7260Q 3-axis accelerometer. It measures positive and negative
acceleration in the X, Y, and Z axes, providing an analog voltage output for each axis. The accelerometer
sensitivity can be adjusted for a maximum scale reading of 1.5, 2, 4, or 6 times the force of gravity.
Figure 6 shows the relationship of the acceleration/deceleration observed by the sensor to the value read
from a 10-bit analog-to-digital converter measuring the sensor output for that axis. Although the
relationship between acceleration/deceleration and output voltage is linear, it naturally falls to the
midpoint voltage when the unit is at rest because the sensor measures acceleration in both directions along
the axis of interest.
For the mounting orientation of the g-sensor brake lamp, increasing deceleration results in decreasing
output voltage. With the board mounted exactly vertically, this force appears entirely in the Z axis.
Therefore, the harder you brake, the lower the output voltage on the Z axis output and the lower the ADC
result value.
The diagram also shows that even though the ADC reference voltage is set to 5 V, the operating voltage of
the MMA7260Q is only 3 V. This results in the maximum 10-bit ADC reading of around 614 (rather than
1024). The reference voltage for the ADC must remain at 5 V to monitor parameters in the analog portion
of the MM908E625, which reduces system sensitivity.
g-Sensor High-Brightness LED Brake Lamp, Rev. 0
Freescale Semiconductor
5
Accelerometers: The Key to the System
Figure 6. Translation of Deceleration and Acceleration into ADC Readings
In the g-sensor brake lamp application, deceleration is the only data of interest. Any ADC reading above
the stopped reading of around 300 to 330 is ignored (presuming board is mounted vertically).
2.2
Collecting Acceleration/Deceleration Data
During testing, the ZSTAR wireless sensing triple axis reference design was employed to collect
deceleration-force data. The ZSTAR design combines the same MMA7260Q three axis accelerometer with
a pair of Freescale’s MC13191 2.4 GHz ISM band low-power transceivers. One transceiver is on a board
with the accelerometer, and the other is on a board which uses Freescale’s MC68HC908JW32 MCU to
allow the transceiver to plug into a USB port. Therefore, sensor data can be transmitted wirelessly to a
laptop from a small, portable, battery-powered board.
To ensure that maximum reasonable braking forces were measured, the sensor board was mounted to the
rear of a motorcycle (approximately 400 pound curb weight — wet). The mounting was achieved by
drilling holes into a plastic inspection-sticker plate, attaching the PCB to this plate with zip ties, and
mounting the inspection sticker plate below the license plate. This approximates the final mounting of the
brake lamp assembly except that the Z axis is inverted because the MMA7260Q is mounted facing the rear.
Figure 7 shows this mounting arrangement.
g-Sensor High-Brightness LED Brake Lamp, Rev. 0
6
Freescale Semiconductor
Accelerometers: The Key to the System
Close-up of mounting
Figure 7. Z-Star g-Sensor Data Collection Mounting
The data was then collected while driving the motorcycle in a straight line to a specified speed then braking
to a stop with various pressures. The goal was determining the brake-forces parameters.
Attempts were made to retrieve data while driving past a stationary laptop, but the distances required to
reach initial speed (20 MPH to 40 MPH) and maintain distance from the data recorder proved too far for
the transceivers. Finally, to maintain the wireless link, the laptop was strapped to the rear seat.
With a reliable connection, numerous data collection runs were performed at varying speeds and braking
forces. Figure 8 shows a graph of about 45 seconds of a typical data-collection run. The maximum
deceleration during braking appears nearly full scale but does not seem to saturate. This indicates that the
approximate maximum brake forces were 1.5 g (255 on an 8-bit scale with board mounted in this
orientation). This allows for proper sensitivity adjustment of the MMA7260Q.
The vibrational noise also appears in the data with the acceleration/deceleration information. This is the
largest design issue to overcome when determining the actual state of the vehicle at any time.
g-Sensor High-Brightness LED Brake Lamp, Rev. 0
Freescale Semiconductor
7
Accelerometers: The Key to the System
Figure 8. Raw 8-Bit Accelerometer Data
2.3
Managing Vibration and Noise
Vibration is a concern, particularly on a motorcycle, where the vehicle’s mass is relatively small and does
not dampen the vibrations of the road and engine. The following section addresses the vibration issue and
the resulting noise produced in the data.
2.3.1
Mechanical Considerations
The fundamental way to handle vibration is to isolate the sensor from the vibration mechanically. This is
particularly difficult on a motorcycle. Mounting the lamp on the motorcycle’s luggage case was the best
method of mechanical isolation (Figure 5). This deflected the suspension and the rider’s mass and,
therefore, dampened road and engine vibration.
2.3.2
Analog Filtering
After all mechanical means of isolation are taken, the analog circuitry on the ADC inputs from the
MMA7260Q can also be controlled to filter additional vibrational noise. Each sensor output has an RC
filter that can be tuned to reduce higher frequency noise. Because the application is concerned only with
relatively slow changes in the deceleration, ignore rapid changes (that is, high-frequency noise). Tuning
the resistance or capacitance on these RC filters can reduce high-frequency noise. Consult the data sheets
before selecting final values.
g-Sensor High-Brightness LED Brake Lamp, Rev. 0
8
Freescale Semiconductor
2.3.3
Software Filtering
After mechanical and electrical means of filtering are exhausted, the application has a third level of
filtering. This filtering is done in the software and is comprised of three components:
• Digital low-pass filtering
• State machine state-processing delay
• Threshold hysteresis
The digital low-pass filter keeps a running average of the measured deceleration values. The sample rate
and time constant for this filter are configurable, but the more noise filtered out, the slower the system
response. Figure 9 shows the code for the digital LP filter.
#define TIME_CONST
#define SAMP_RATE
#define DIVIDER
0.05
400
// Time constant for averaging deceleration values
// Sample rate of system
(TIME_CONST*SAMP_RATE)
…
UINT16 Current_Decel_Reading;
// Current deceleration reading
UINT16 Last_Decel_Reading;
// Previous deceleration reading
UINT16 Decel_Reading_Accum;
// Accumulated deceleration reading
UINT16 Decel_Value;
// New deceleration value
Last_Decel_Reading
= *ADC_Value10(Z_AXIS_INPUT);
// Initialize LP filter variable
…
For(;;)
{
…
Current_Decel_Reading
Decel_Reading_Accum
Decel_Value
Last_Decel_Reading
…
}
=
=
=
=
*ADC_Value10(Z_AXIS_INPUT);
// Update current reading
Decel_Reading_Accum + (Current_Decel_Reading - Last_Decel_Reading);
Decel_Reading_Accum/((UINT16)(DIVIDER));
// Calculate new average
Decel_Value;
// Update "last reading“
Figure 9. Code Example for Digital Low-Pass Filter
The configurable state machine processing delay is the second software technique for controlling the noise
in sampling deceleration. This should not be confused with the actual sampling rate of the digital filter.
Because the filter samples only one time per cycle through the main loop in this example code, the state
machine processing delay can affect the sampling rate of the entire system. Therefore, the longer that loop
takes to execute, the less frequently the MCU samples the deceleration rates. This can further control the
sample rate of the low-pass filter, but in the code example shown, the state machine processing delay is
minimized to smaller than the LP filter sample rate prevent this effect.
The final software method to control vibration and noise prevents oscillation between states when the
deceleration value is close to the threshold between two states. Inserting hysteresis into the state transitions
does not filter out noise in the data, but it does filter the output to the HBLEDs such that the brake lamp
does not flicker noticeably when transitioning between two braking-level indications. Figure 10 shows
how this hysteresis works for state changes.
Driving the High Brightness LEDs
Figure 10. State Change Hysteresis
For example, when the deceleration reaches 20% of maximum, the state machine moves to level 1 (two
HBLEDs lit). It remains in this state even if the deceleration drops a little due to noise. Deceleration must
drop below 10% before the state machine allows the software to turn off the lights and return to level 0.
3
Driving the High Brightness LEDs
3.1
Basic HBLED Drive Channels with MM908E625 Half-Bridges
One advantage of using the MM908E625 device for this application is that the MCU is integrated with
advanced, fully protected power circuitry. Included in this circuitry are four, half-bridge-power stages that
can drive motors and higher current loads.
The low side of each half bridge. is used to drive a pair of HBLEDs and provide a constant current supply
to the HBLEDs. These low-side switches have configurable current limits that automatically prevent
overcurrent to the load and can be preset to 55 mA, 260 mA, 370 mA, 550 mA, or 740 mA (typical). This
works well for this application, where the average load current should be around 350 mA. Additionally,
g-Sensor High-Brightness LED Brake Lamp, Rev. 0
10
Freescale Semiconductor
Driving the High Brightness LEDs
the low-side drivers of the half bridges provide a current recopy feature to allow the MCU to measure the
actual current to the load through an ADC channel.
The only external component required to drive the HBLEDs is an inductor to manage load current ripple.
Figure 11 shows circuit layout. Selection of this inductor value is a function of the switching frequency of
the switch, the operating voltage to the drive circuit, and the total forward voltage drop of the HBLEDs.
The half-bridge output includes a freewheel diode to dissipate the voltage spike that results when the
switch is turned off.
Figure 11. Basic High Brightness LED Drive Circuit Using MM908E625 Low-Side Switches
Because the low-side driver of the half bridge prevents overcurrent of the HBLEDs, control brightness by
controlling the driver’s on time. Figure 12 shows the cathode voltage of one drive channel of HBLEDs at
three different brightness intensities. While the drive channel is on, the current limitation rapidly switches
on and off, while the brightness switching occurs at a lower frequency. For specific frequencies, refer to
the code for this application note. In this example, the brightness switching is around 200 Hz and the
current limitation is switching about 20 kHz.
Figure 12. Voltage Measured at LED Cathode (Low, Medium, High Intensities Respectively)
Another benefit is the offset chopping feature that spreads the peak switching currents to reduce radiated
emissions. If bit OFC_EN in the H-bridge control (HBCTL) register is set, HB1 and HB2 continue to
switch on the low-side MOSFETs with the rising edge of the FGEN clock signal and HB3, and HB4 switch
on the low-side MOSFETs with the falling edge on the FGEN clock input.
Details of how to use the MM908E625 half bridge outputs to regulate current in HBLEDs can be found in
application note AN3321 High-Brightness LED Control Interface. This also describes other methods of
controlling HBLEDs.
g-Sensor High-Brightness LED Brake Lamp, Rev. 0
Freescale Semiconductor
11
Additional System Features
3.2
Additional LED Control Circuitry
Because the MM908E625 device has only four half-bridge outputs, it can only drive four channels of
HBLEDs. This would be sufficient for the progressive brake-lamp output showing deceleration of the
vehicle, where two HBLEDs could be ganged onto each drive channel and placed on either side of the
center of the board. This would allow each LED drive channel to control a pair of HBLEDs centered
around the center of the board. For added flexibility in the design, however, individual control of all eight
HBLEDs was desired.
To control eight HBLEDs with only four drive channels, solid state optical relays were added in parallel
to each HBLED to allow for bypassing the HBLED to switch either HBLED off while the drive channel
is on. Figure 13 shows how these relays work. In this figure, when the relays are disabled, as in the left
picture, both HBLEDs are lit. If only one of the HBLEDs is lit, the relay corresponding to the HBLED to
be extinguished is activated. See the right diagram of Figure 13, where HBLED2 is bypassed and the
current flows through the relay instead of HBLED2, only allowing HBLED1 to light.
Figure 13. LED Drive and Control Circuitry — Photo Relays Disabled and Enabled
4
Additional System Features
•
•
•
License plate illumination — The single high-side driver output (HS) on the MM908E625 is used
to drive white LEDs designed to illuminate the vehicle license plate. The board design is such that
it can be integrated into the top side of an aftermarket license plate frame and the white LEDs
would shine down onto the plate.
Daylight brightness compensation using photo sensor — A light-sensitive photo resistor is
connected to the dedicated analog input terminal, which supplies its own selectable constant
current source. This sensor measures ambient light levels so the brightness of the HBLEDs can be
increased during daytime for better visibility and reduced during nighttime to prevent blinding
other drivers.
Monitoring of 12 V vehicle signaling — Design uses the MM908E625 hall-effect sensors to
monitor the status of the vehicle brake lamps and the left and right signal indicator lamps.
Transistors allow monitoring lamp voltage without drawing current from the lamps themselves.
This is important in the case of motorcycles that have advanced, adaptive brake lamp controllers
that monitor the current consumption of the brake lamps to detect faults. The vehicle could
misinterpret the excess current on the brake-lamp supply as a wiring fault.
g-Sensor High-Brightness LED Brake Lamp, Rev. 0
12
Freescale Semiconductor
Software Design
•
LIN networking capability — Although not detailed here, the g-sensor brake lamp will
communicate as a slave on a LIN automotive network. It is currently only set up to respond to the
0x3C and 0x3D reserved LIN system command identifiers. For details on LIN messaging
configuration, refer to the source code, specifically, the "l_gen.h" and "l_gen.c" files,and the LIN
driver manuals for HC908EY16.
5
Software Design
5.1
Software State Machine
The central functionality of the brake lamp design is in the basic state machine for the software. There are
essentially six normal operating states with up to 18 sub-states based on turn signal flasher status.
Figure 14 shows these states, where the initial reset state is shown as a black dot.
Figure 14. g-Sensor Brake Lamp Software State Machine (Includes Turn Signal Functionality)
The states represent the various deceleration levels and, therefore, the variable LED display patterns. The
fundamental states are:
• CALIBRATE - (not implemented in sample code) — When activated, the brake lamp assumes it is not
moving and is in the correct neutral position for calibration. For a motorcycle, this requires that the
bike stand vertically (not on a kick-stand). Gravity is used to determine the down direction and,
therefore, the forward and backward directions and the X,Y, and Z components of sensor data
required to measure deceleration in the forward direction of travel.
g-Sensor High-Brightness LED Brake Lamp, Rev. 0
Freescale Semiconductor
13
Software Design
NOTE
The following states contain three sub-states for left, right, or both turn
signals activated. Left turn only and right turn only states are shown in the
state machine diagram, but not the case of both left and right active at the
same time. This would be applicable only to vehicles with emergency
flashers where both turn signals blink together. This is less common in
motorcycles.
•
•
•
•
•
•
STOPPEDALERT — Displays the outside two pairs of HBLEDs when there is little or no deceleration,
but the vehicle brake lamp is turned on (indicating that the driver is activating the brakes). This
emulates a standard third brake lamp at low decelerations or traffic lights, to allow a motorcycle
stopped at a traffic light to flash this brake lamp to warn cars approaching from behind that the
motorcycle is present or stopped. Tapping the brake lever causes this flash without braking the
vehicle. Visibility at traffic lights is a common motorcyclist concern.
BRAKE_NO — Displays no HBLEDs and is entered when there is little or no deceleration.
BRAKE_LOW — Displays one pair of HBLEDs for low decelerations (20% to 40% of maximum
deceleration will activate this state).
BRAKE_MEDIUM —Displays two pairs of HBLEDs for moderate decelerations (40% to 60% of
maximum deceleration activates this state).
BRAKE_HIGH — Displays three pairs of HBLEDs for hard decelerations (60% to 80% of maximum
deceleration activates this state).
BRAKE_EXTREME — Displays four pairs of HBLEDs for extremely hard decelerations (80% and
greater of maximum deceleration activates this state). Generally this state is applicable only to
emergency situations. Upon entry into this state, a timer latches the software in brake_extreme state
to maintain the state even after deceleration. When the timer expires, the deceleration
measurements resume control of determining the brake-lamp status. The timer latch is necessary
in emergency braking situations as warning that traffic should continue for at least a few seconds
because the circumstances causing the emergency stop are probably still present.
When a left or right turn signal (or both) is activated, a sub-state is entered from the main braking level
state. The only difference is in the HBLED display. When one turn signal is active, four HBLEDs are lit,
and the other side displays the deceleration level, as determined by the braking force. In its current form,
the software supports only one signal at time with at least some time between with neither lamp active.
5.2
Accelerometer Initialization and Calibration
With the ability to measure acceleration accurately in all three axes, the g-sensor brake lamp can be
calibrated to any mounting angle. Since gravity exerts 1-g of force directly down, the MMA7260Q
measures this accurately. The force that appears in each axis from the sensor gives the MCU enough
information to determine the brake lamp’s mounting position. Since the HBLEDs are always mounted on
one side of the board and the MMA7260Q is always mounted on the other, assume the brake lamp would
be mounted with the HBLEDs facing the rear of the vehicle. This gives the last piece of data required to
determine the forward direction of travel as a function of the X, Y, and Z axis of the accelerometer.
g-Sensor High-Brightness LED Brake Lamp, Rev. 0
14
Freescale Semiconductor
Looking Forward
For example in Figure 15, a board is mounted parallel to the vehicle’s rear axle, but with the HBLEDs
pointing at the sky at a 45% angle instead of facing the horizon directly. This means that from the rear of
the vehicle, the board appears level from left to right, but the top of the board leans toward the front of the
vehicle and the HBLEDs point up. Given the orientation of the MMA7260Q, the sensor outputs voltages
indicating an X axis of +0.5g, a Y axis of 0g, and a Z axis of –0.5g. Because the mounting angle is 45
degrees to the direction of travel, the motorcycle’s deceleration is equally observed in the X and Z axes
equally. When the board is mounted horizontally level, the deceleration is always measured in only the X
and Z axes. Similarly, if the board were mounted so that the HBLEDs were vertically aligned, the
deceleration is always a function of the Y and Z axes.
Figure 15. g-Sensor Brake Lamp Orientation Mounting Calibration Example
To establish the correction factors for vehicle deceleration, consider the direction and orientation of the
axes of the sensor relative to the axis of travel. This calibration algorithm is not currently implemented in
the software, but the deceleration thresholds are saved in an array in flash memory to facilitate
implementing this type of calibration algorithm. The data sheet for the MMA7260Q contains information
on the orientation of the sensor relative to the package to aid in determining the mounting angle of a PCB
in the earth’s gravity field.
6
Looking Forward
Possible design improvements:
• Variable blink rate for each braking level — Deceleration rates would increase, more HBLEDs
would light and also blink faster. Blinking attracts attention and implies greater urgency.
• Always-on running lights — When the HBLEDs are not lit at full intensity, they could operate at
a reduced intensity as a constant running light.
• Implement the calibration algorithm.
• Sequential turn signals — Turn signals that blink sequentially to the left or right, further reinforcing
the turn signal message.
g-Sensor High-Brightness LED Brake Lamp, Rev. 0
Freescale Semiconductor
15
References
•
7
Pothole and incline compensation — Because sudden jolts or constant inclines can affect the
accuracy of the g-sensor brake lamp and compensation, algorithms can be derived and tested.
References
With this application note, the following related files are available for download:
• Software — A complete CodeWarrior™ 5.1 project, written in C language, which includes turn
signal and brake lamp monitor support, as well as LIN drivers.
• Hardware gerber files — Orcad files required to manufacture the PCB
• Reference videos — Videos highlighting the operation and function of the g-sensor brake lamp
Additional information is available at www.freescale.com:
• MM908E625 technical data sheet
• MC68HC908EY16 technical data sheet
• DRM083 — High Brightness LED Driver Using the MM908E625 Design Reference Manual
• LIN driver manuals for HC908EY16, available on www.freescale.com/LIN
• MMA7260Q technical data sheet
• AN3107 — Measuring Tilt with Low-g Accelerometers
• AN3111 — Soldering the QFN Stacked Die Sensors to PC Board
• AN3152 — Using the Wireless Sensing Triple Axis Reference Design
• RD3152MMA7260Q — Wireless Sensing Triple Axis Reference Design (ZSTAR)
g-Sensor High-Brightness LED Brake Lamp, Rev. 0
16
Freescale Semiconductor
$
+%
&
X)
8
/ P+
.
. .
)
)
26&
9
+%/('
&
X)
)86(
&\FORQH
-
37%
37%
- &21
+%/('
'
8
$4<6
5 .
&
8)
+%
,54B$
&
8)
/('&WUO
9%DW
/ P+
5(6(7
+%
,54&
37$
37$
9%DW
66
5(6(7
&
S) +%
/,1
')/7$
'
&
X)
/('&WUO
' ',2'(
5
.
9
&
X)
8
$4<6
+%/('
'
5 N
=B6(16
5 .
1&
1&
1&
6/((302'(
)86(7+(50$/
9%DWLQ
'
8
$4<6
5 .
00$4
9VV
9GG
*6(/(&7
*6(/(&7
N
/('&WUO
5
5 5
<B6(16
9
.
5
1&
*VHO,Q
1&
5
1&
.
;RXW
1&
=RXW
<RXW
1&
&
X)
9%DWLQ
+%/('
'
*1'
%UDNH6:
7XUQ5
7XUQ/
/,1
9%DW
/('&WUO
&21
-
+%
'
:KLWH/('
'
:KLWH/('
+%
'
:KLWH/('
5
.
5
.
/ P+
/('&WUO
+%
%UDNHB8
7XUQ5LJKWB8
7XUQ/HIWB8
3$
&
X)
'
:KLWH/('
5
.
,54B$
,54
,54&
'
:KLWH/('
5
.
+%/('
'
8
.
$4<6
5
9
/('&WUO
/('&WUO
/('&WUO
&
X)
/('&WUO
37$
37$
/('&WUO
5
.
8
.
$4<6
5
5
.
MM908E625
37%$'7%&+ 37$.%'
37%$'7%&+ 37$.%'
37$.%'
37&26&
)/6933
37&26&
37$.%'
37&0&/.
37$.%'
37%$'
95()+
37%$'
9''$
37%$'
(9''
Q,54
Q567
(966
37%$'
966$
37'7$&+%(0)
95()/
37'7$&+
37(5;'
1&
5;'
)*(1
966
%(0)
3$
Q567B$
9''
Q,54B$
+
Q66
+
/,1
+
1&
+9''
1&
1&
+%
+%
9683
9683
*1'
*1'
+%
+%
9683
+6
*VHO,Q
*VHO,Q
/('&WUO
26&
/('&WUO
/('&WUO
;B6(16
37%
37%
<B6(16
37%
,54
5(6(7
=B6(16
&21
-
+%/('
'
9%DW
5 .
7XUQ/HIWB8
7XUQ5LJKWB8
%UDNHB8
4
1$
5
/('&WUO
4
1$
5
4
1$
5
'
0$=+&/71'
$4<6
8
9
9
5
5
.
5
*VHO,Q
+%
.
.
.
6L]H
7LWOH
/ P+
/('&WUO
5
.
5
5
.
5
5
.
5
$4<6
8
5 .
+%/('
'
*6HQVRU%UDNH/DPS
+%/('
'
'RFXPHQW1XPEHU
5HY1R
8
.
$4<6
5
7XUQ/
7XUQ5
%UDNH6:
8
3$
Freescale Semiconductor
9%DW
/('&WUO
8
5 3KRWR5HV
Schematics
Schematics
g-Sensor High-Brightness LED Brake Lamp, Rev. 0
17
Schematics
8.1
Bill of Materials
Table 1. Bill of Materials
Quantity
per PCB
Designator
Value / Description
Supplier Part Number
Supplier
1
U9
MM908E625
MM908E625ACDWB
Freescale
1
U10
MMA7260Q
MMA7260Q-ND
Freescale
1
C1
100pF
PCC101CGCT-ND
DIGIKEY
10
C4,C5,C6,C7,C9,C10,C21
0.1uF
PCC1840CT-ND
DIGIKEY
1
C8
4.7uF
587-1294-1-ND
DIGIKEY
2
C11, C1100”
100uF
478-1724-1-ND
DIGIKEY
1
D1
DIODE S
CMS03CT-ND
DIGIKEY
5
D2,D3,D4,D5,D6
White LED
516-1468-ND
DIGIKEY
1
D7
DFLT22A
DFLT24ADICT-ND
DIGIKEY
1
D29
MAZ80330HCLT-ND
MAZ80330HLCT-ND
DIGIKEY
8
D31,D32,D33,D34,D35,D36 HBLED1 (Red Luxeon I
,D37,D38”
emitter)
LXHL-PD01-LF
1
F1
NEW FUSE THERMAL
RUEF400-ND
DIGIKEY
1
F2
New Slow FUSE
F2571CT-ND
DIGIKEY
1
J1
CON6
A33965-ND
DIGIKEY
4
L1,L2,L3,L4
1mH
513-1217-1-ND
DIGIKEY
3
Q1,Q2,Q3
2N2222A transistor
568-1741-1-ND
DIGIKEY
1
R1
PhotoRes
PDV-P9001-ND
DIGIKEY
5
R2,R7,R33,R36,R39
10K
P10KACT-ND
DIGIKEY
11
R3,R4,R5,R21,R22,R23,
R24,R25,R26,R27,R28
1K
P1.0KACT-ND
DIGIKEY
1
R6
20K
P20KACT-ND
DIGIKEY
5
R9,R10,R11,R12,R13
1.5K
P1.50KFCT-ND
DIGIKEY
2
R14,R16
4.7K
P4.7KACT-ND
DIGIKEY
2
R15,R18
3.1K
P3.3KACT-ND
DIGIKEY
1
R19
180
P180ACT-ND
DIGIKEY
3
R20,R34,R37
750
P750ACT-ND
DIGIKEY
3
R30,R35,R38
40K
P40.2KCCT-ND
DIGIKEY
8
U1,U2,U3,U4,U5,U6,U7,U8 AQY212S
1
J2
Cyclone Header (2x8
header, 0.1” centers)
1
J3
CON2 (1x2 header, 0.1”
centers)
1
J4
CON3 (1x3 header, 0.1”
centers)
AQY212S-LF
FUTURE Electronics
FUTURE Electronics
g-Sensor High-Brightness LED Brake Lamp, Rev. 0
18
Freescale Semiconductor
THIS PAGE IS INTENTIONALLY BLANK
How to Reach Us:
Home Page:
www.freescale.com
E-mail:
[email protected]
USA/Europe or Locations Not Listed:
Freescale Semiconductor
Technical Information Center, CH370
1300 N. Alma School Road
Chandler, Arizona 85224
+1-800-521-6274 or +1-480-768-2130
[email protected]
Europe, Middle East, and Africa:
Freescale Halbleiter Deutschland GmbH
Technical Information Center
Schatzbogen 7
81829 Muenchen, Germany
+44 1296 380 456 (English)
+46 8 52200080 (English)
+49 89 92103 559 (German)
+33 1 69 35 48 48 (French)
[email protected]
Japan:
Freescale Semiconductor Japan Ltd.
Headquarters
ARCO Tower 15F
1-8-1, Shimo-Meguro, Meguro-ku,
Tokyo 153-0064
Japan
0120 191014 or +81 3 5437 9125
[email protected]
Asia/Pacific:
Freescale Semiconductor Hong Kong Ltd.
Technical Information Center
2 Dai King Street
Tai Po Industrial Estate
Tai Po, N.T., Hong Kong
+800 2666 8080
[email protected]
For Literature Requests Only:
Freescale Semiconductor Literature Distribution Center
P.O. Box 5405
Denver, Colorado 80217
1-800-441-2447 or 303-675-2140
Fax: 303-675-2150
[email protected]
Document Number: AN3380
Rev. 0
12/2006
Information in this document is provided solely to enable system and software
implementers to use Freescale Semiconductor products. There are no express or
implied copyright licenses granted hereunder to design or fabricate any integrated
circuits or integrated circuits based on the information in this document.
Freescale Semiconductor reserves the right to make changes without further notice to
any products herein. Freescale Semiconductor makes no warranty, representation or
guarantee regarding the suitability of its products for any particular purpose, nor does
Freescale Semiconductor assume any liability arising out of the application or use of any
product or circuit, and specifically disclaims any and all liability, including without
limitation consequential or incidental damages. “Typical” parameters that may be
provided in Freescale Semiconductor data sheets and/or specifications can and do vary
in different applications and actual performance may vary over time. All operating
parameters, including “Typicals”, must be validated for each customer application by
customer’s technical experts. Freescale Semiconductor does not convey any license
under its patent rights nor the rights of others. Freescale Semiconductor products are
not designed, intended, or authorized for use as components in systems intended for
surgical implant into the body, or other applications intended to support or sustain life,
or for any other application in which the failure of the Freescale Semiconductor product
could create a situation where personal injury or death may occur. Should Buyer
purchase or use Freescale Semiconductor products for any such unintended or
unauthorized application, Buyer shall indemnify and hold Freescale Semiconductor and
its officers, employees, subsidiaries, affiliates, and distributors harmless against all
claims, costs, damages, and expenses, and reasonable attorney fees arising out of,
directly or indirectly, any claim of personal injury or death associated with such
unintended or unauthorized use, even if such claim alleges that Freescale
Semiconductor was negligent regarding the design or manufacture of the part.
Freescale™ and the Freescale logo are trademarks of Freescale Semiconductor, Inc.
All other product or service names are the property of their respective owners.
© Freescale Semiconductor, Inc. 2006. All rights reserved.
RoHS-compliant and/or Pb-free versions of Freescale products have the functionality
and electrical characteristics as their non-RoHS-compliant and/or non-Pb-free
counterparts. For further information, see http://www.freescale.com or contact your
Freescale sales representative.
For information on Freescale’s Environmental Products program, go to
http://www.freescale.com/epp.