Bike Wheel Light PCB

by JeremySCook in Circuits > LEDs

9700 Views, 69 Favorites, 0 Comments

Bike Wheel Light PCB

logo-template-wheel-light-r1.jpg

Riding a bicycle at night can be dangerous. Having lights on your bike can help, even better if they come on automatically!

Video:

Automatic Bike Wheel Light [PCB]

Video goes through some of the finer points on this build, including my first try at it using primarily through hole components. Surface mount components is a new animal to me, and it really opens up a lot of possibilities.

Supplies

Bike Light4.jpg
  • PCB - KiCAD project available on GitHub, PCBs produced by NextPCB
  • ATtiny85-20SU [eBay]
  • Low Sensitivity Vibration Sensor [eBay] or [Adafruit]
  • 0805 resistors (4) a sample book [Amazon] can be extremely useful
  • 0805 LEDs (4) [Amazon]
  • CR2032 Battery
  • CR2032 Battery holder [eBay] [Amazon] - as seen in video, had a hard time with either one
  • Solder paste [Amazon]
  • DIP switch (1 position - optional, can use wire instead)
  • Capacitor (2200uF used, could likely go smaller)
  • Zip ties (4)

Tools

Bike Light3.jpg
  • Hot air gun [Amazon] - extremely useful with SMD parts as well as heat shrink.
  • Solder squid (optional) - my concrete design.
  • Programmer [Sparkfun] and chip clip

Melty Melty!

Screen Shot 2021-01-30 at 8.57.00 AM.png
Screen Shot 2021-01-30 at 8.58.40 AM.png

Apply parts, melt solder paste, solder on surface mount components.

Program

DSC06949.JPG

Program the ATtiny85 using a programmer and chip clip. More info on programming this chip is found here. Code is based on this previous project, and simply cycles from one LED to another.

Note that while ICSP headers seem to be available, I made an error or two here–best to use the clip.

Zip Up!

Screen Shot 2021-01-30 at 9.06.06 AM.png

The PCB is designed to attach to a bike's spokes via zip ties. Loop the ties as appropriate and tighten.

Ride!

Bike Light2.jpg

With this in place, when your wheels go above a certain speed, power is applied the lights will start flashing. An earlier revision started flashing by hooking the sensor up to the reset. This worked at lower speeds, but at high speeds the reset is simply triggered all the time.

Next Steps

Screen Shot 2021-01-30 at 9.37.26 AM.png

While this build works, there are a few things that could be improved:

  • Battery life isn't great - larger resistors, or more efficient LEDs could be used. Also, one might consider taking out the ATtiny85 altogether and running it off of a blinking capacitor.
  • Blinking happens only at certain speeds depending on the revision. Ideally a device would do both, so I wouldn't rely on this as a primary safety device. I still have a light on my bike that I turn on manually.

If you enjoyed it and/or found it useful, this writeup is entered into the PCB contest, and I'd love your vote. Thanks for reading!

Note that Amazon links on this Instructable are affiliate, meaning I get a small percentage of purchases executed after clicking those links.