Inertial LED brake light for bicycle

Thread Starter

tracecom

Joined Apr 16, 2010
3,944
I want to build an LED brake light for a bicycle. I don't want any mechanical switches connected to the pedals. I have, for the moment, ruled out measuring the wheel speed to see when it is increasing or decreasing. I have also thought about using GPS to measure the speed, but am afraid there might be too much lag time. For now, I want to use inertia to control the LEDs.

The budget is not unlimited, but I don't have to have the lowest cost possible. Rather, I want the best operation possible.

The basic idea is that deceleration causes the LEDs to light, and a lack of deceleration causes the LEDs to go out. I don't want bumps in the road to cause flickering. I don't want riding up a hill to cause the LEDs to light, but I do want the LEDs to light during deceleration while going downhill and/or leaning (i.e., I want the circuit immune to the inclination attitude of the bicycle, both front to back and side to side.) It may be that the circuit needs to differentiate between slowing down while coasting and actual breaking, but maybe not.

I know that there are such things as electronic accelerometers, but I have never used one. Perhaps that is the best way to sense deceleration and cancel out the effect of inclination attitude? I have some experience with micro-controllers and will use one if needed.

The unit is to be battery powered, but can be whatever voltage works best. To conserve battery life, it would be nice if the circuit went into a power-off mode during periods of inactivity (no motion.)

Your input is solicited. Thanks.
 
Last edited:

wayneh

Joined Sep 9, 2010
17,496
Cool idea, very challenging. We saw a bicycle lighting thread closed here for violating the Automotive ban though, so I'm not sure how far this will go.

You said pedals. Do you intend this for coaster brakes?

In my opinion, no accelerometer-based or indirect solution can be as reliable as one based on directly sensing either the application of the brakes by the operator or the actual application of a brake to a wheel. I agree you don't want moving parts, but I do think you could sense braking.
 

Thread Starter

tracecom

Joined Apr 16, 2010
3,944
Here's one that I could buy, but I (with the help of AAC members) want to design and build one.

http://www.sungoinc.com/light/products.html

You said pedals. Do you intend this for coaster brakes?
I would like it to work with coaster brakes or hand brakes. In addition, I would like it to be adjustable so that it could react to deceleration due to any cause, e.g., foot dragging. Strictly a warning to traffic that the bike is slowing down.

To all: I have a couple of errands to run, so won't be at the computer for a while. Please continue to post thoughts/ideas/suggestions.
 
Last edited:

wayneh

Joined Sep 9, 2010
17,496
Strictly a warning to traffic that the bike is slowing down.
Hmmm, so that's different than the traditional car brake light logic. A purely speed-based solution would trigger when coasting up an incline, since you will obviously be slowing down. But you said you want to NOT light up if the slowing is caused by an incline? That means you need to sense the incline in addition to speed.
 

wayneh

Joined Sep 9, 2010
17,496
Here's one that I could buy,
Well that one is clearly using an accelerometer - no external sensing - and I doubt very much it senses incline. I suspect it is "desensitized" so that it does not trigger unless the deceleration is sizable. So for instance an 8% incline might not trigger it, but perhaps a 20% would. (Of course you have bigger problems on a 20% grade!).

It may calibrate itself based on the inclination of the light when it's turned on, though. Other wise I think you could have a problem with the light not being installed level, and that would cause a bias in detecting deceleration.
 

crutschow

Joined Mar 14, 2008
34,280
If you differentiate the signal from an accelerometer with the proper time-constant you may be able to tell the difference between a slow change in signal due to an incline and the faster change due to braking. It may be difficult to differentiate between an incline and a slow-down due to foot dragging, however. You'd have to play with the time-constant to find the optimum value.
 

Markd77

Joined Sep 7, 2009
2,806
With a 3 axis accelerometer you can use a bit of maths to work out the magnitude of acceleration, if it's about 1G that's just normal, more than 1G and there is some acceleration or deceleration going on. Then you work out the direction and decide if the light needs to go on. It would be fairly insensitive to mounting position.
 

crutschow

Joined Mar 14, 2008
34,280
With a 3 axis accelerometer you can use a bit of maths to work out the magnitude of acceleration, if it's about 1G that's just normal, more than 1G and there is some acceleration or deceleration going on. Then you work out the direction and decide if the light needs to go on. It would be fairly insensitive to mounting position.
All you need is a single-axis accelerometer with the acceleration axis parallel to the bike frame. In that orientation it will be insensitive to gravity when operating on level ground. Any acceleration reading then means you are accelerating, slowing down, or going up or down a grade.
 

Sensacell

Joined Jun 19, 2012
3,432
Very cool idea.

I bet it's going to be hard to make it work without an appreciable delay, which is not a desirable attribute in a brake light. Discriminating the pulsing acceleration caused when you stand up and really push the pedals will require a long time constant in your filter.
 

BillO

Joined Nov 24, 2008
999
Leaning should not be a problem. Neither should cycling up a hill as that is acceleration. However, going down a hill at a constant speed IS deceleration. Either that or we can now officially throw the laws of physics out.

Even wind resistance and rolling resistance may produce a decent amount of deceleration while free-wheeling down hill depending on your initial speed.

I think you will have to put up with the light going on while going down hill in certain cases (deceleration beyond a certain threshold) or use both an accelerometer and a gyroscope so that you can determine the bike's attitude.

Edit: Just read the link you provided to the other light. They say it will only operate with "material" deceleration, and not slight deceleration. So that is the key in duplicating their effort. You need just to set the threshold correctly.
 
Last edited:

#12

Joined Nov 30, 2010
18,224
At first glance, decelerating and going downhill are the same thing from a point of reference on the bicycle. You have your work cut out for you!
 

crutschow

Joined Mar 14, 2008
34,280
Yes, from a physics point-of-view constant acceleration (or deceleration) cannot be differentiated from the gravitational force. You'd have to use a gyroscope to measure your attitude to detect going downhill and inhibit the brake for that condition.
 

Kermit2

Joined Feb 5, 2010
4,162
What about using a counting scheme.

a photodetection circuit that counts interrupts caused by the spokes of a wheel. Followed with a freq to voltage convertor.

If a micro is used then variations that are slower than a preset value would not need to be 'sensed', so a gradual decleration could be ignored, like the slowing involved in biking up an inclined surface. When the change in freq is faster then...
 

wayneh

Joined Sep 9, 2010
17,496
I don't think it's that hard. A steep hill is usually less than a 10% grade. Anything more than that and you've likely got your brakes on anyway. A 10% grade is only 0.17g in the forward direction. If you set the threshold at 0.2g, it'd almost never turn on due to an incline.

Don't forget, the device already exists, appears to work, and isn't all that expensive.
 

Thread Starter

tracecom

Joined Apr 16, 2010
3,944
I don't think it's that hard. A steep hill is usually less than a 10% grade. Anything more than that and you've likely got your brakes on anyway. A 10% grade is only 0.17g in the forward direction. If you set the threshold at 0.2g, it'd almost never turn on due to an incline.

Don't forget, the device already exists, appears to work, and isn't all that expensive.
I am thinking of a single axis accelerometer home-built using a linear hall effect sensor and a magnet mounted on a flat spring. During deceleration, the spring would flex, allowing the magnet to move closer to the hall effect sensor. The output from the sensor would be connected to an A/D input on a PIC. Another pot configured as a voltage divider would be connected to a second A/D input on the PIC; it would be used to adjust the turn-on point of the brake light. A timer function in the PIC might prove useful to prevent the LEDs from flickering due to vibration.

It's worth a try, don't you think?
 
Top