L
LPEL88
- Jan 1, 1970
- 0
I have a device which detects when the vehicle brakes are applied and does
some various data gathering with a microcontroller.
The detection is done by putting a tap connector on the power wire to the
brake light. The problem I am having is that I am getting 'false senses'.
The circuit between the wire and the microcontroller is through a resistor,
then through a reverse biased zener (about 6V), then I have a resistor
pulling to ground, and a cap to ground and I'm using an NPN to switch the
pin on the microcontroller to ground. This works flawlessly on 99% of
vehicles.
Problem is very very very occasionally I get false signals. It happens
always on about 1 in 100 vehicles, but never on the other 99. Unfortunately
I do not have access to the vehicles first hand to do any testing, but some
folks are seeing 10-12 volts on the power line going to their brake light
EVEN when the brake is not applied! The brake light does NOT illuminate.
Bear in mind my the circuit is NOT connected during testing.
The only thing I can think is there is a voltage on the line, but at a very
low current which is not enough current to illuminate the brake light, but
enough to cause my circuit to see a brake signal. I have confirmed that
when my circuit is connected, the transistor switches and my microcontroller
reads it as "brake applied", but when the wire is plugged back into the tail
light, it does not happen. This seems to me to be a very low current (not
enough to light the bulb) on the line with enough voltage to trip my input.
Maybe I'm thinking about this too much and missing the forest for the
trees - but does anyone have any ideas? I can't for the life of me figure
out why a brake line would have 11 or so volts on it when the brake is not
applied. When the user applies the brakes, the voltage goes from 11.2 or so
up to 12.4 or so. Considereing 1 out of 100 have this problem, my first
thought is a problem with the vehicle, but the brake lights work great, just
my MCU is getting a false signal. Can anyone suggest anything that may
help? I'm wondering if I should have some current threshold and if so, what
is the easiest and best way to achieve that?
Any insight is appreciated - either on how to solve the problem or what
might be causing it in the first place!
Thanks,
LP
some various data gathering with a microcontroller.
The detection is done by putting a tap connector on the power wire to the
brake light. The problem I am having is that I am getting 'false senses'.
The circuit between the wire and the microcontroller is through a resistor,
then through a reverse biased zener (about 6V), then I have a resistor
pulling to ground, and a cap to ground and I'm using an NPN to switch the
pin on the microcontroller to ground. This works flawlessly on 99% of
vehicles.
Problem is very very very occasionally I get false signals. It happens
always on about 1 in 100 vehicles, but never on the other 99. Unfortunately
I do not have access to the vehicles first hand to do any testing, but some
folks are seeing 10-12 volts on the power line going to their brake light
EVEN when the brake is not applied! The brake light does NOT illuminate.
Bear in mind my the circuit is NOT connected during testing.
The only thing I can think is there is a voltage on the line, but at a very
low current which is not enough current to illuminate the brake light, but
enough to cause my circuit to see a brake signal. I have confirmed that
when my circuit is connected, the transistor switches and my microcontroller
reads it as "brake applied", but when the wire is plugged back into the tail
light, it does not happen. This seems to me to be a very low current (not
enough to light the bulb) on the line with enough voltage to trip my input.
Maybe I'm thinking about this too much and missing the forest for the
trees - but does anyone have any ideas? I can't for the life of me figure
out why a brake line would have 11 or so volts on it when the brake is not
applied. When the user applies the brakes, the voltage goes from 11.2 or so
up to 12.4 or so. Considereing 1 out of 100 have this problem, my first
thought is a problem with the vehicle, but the brake lights work great, just
my MCU is getting a false signal. Can anyone suggest anything that may
help? I'm wondering if I should have some current threshold and if so, what
is the easiest and best way to achieve that?
Any insight is appreciated - either on how to solve the problem or what
might be causing it in the first place!
Thanks,
LP