I love to ride my bike, usually I use it to get to school. In the winter time, it is most often still dark outside and it is hard for other vehicles to see my hand turn signals. Therefore it is a big danger because trucks may not see that I want to turn and think that I drive forward, and then there would be a accident which is often deadly.
It can also be used by people which are not able to give signs with their hand, which is why I partcipate in the assisive tech challenge. But you have to consider that the person, who has for example a disablity, can ride the bike safely in public. You can modify the parts to be attached to a three-wheeled bike.
This is why I made this bikelight with a useful turn signal and cool animations when not driving. I made it Open Source that you can make it too! I have a 3D-printer and this is my first big project with it, it is a very good learning process and I learned a lot while doing it. I still have some ways to improve, if you can help me, feel free to leave tips and tricks!
This project is not really the best version because it has some points to improve (read at the last step) but it can be used as it is now.
Thank you, SainSmart, for sending me the filament and the Arduino Nano used in this project for free. I will leave a link (* means sponsored) to their products because I can mostly recommend them to you!
Disclaimer: Before making this project, make sure to check if it is legal to mount these kind of devices to your vehicle in the public.
You will need the following components:
For the PCB and the electronics:
- 1x PCB, I let AISLER produce mine and I can strongly recommend it to you. Use the gerber files from the top and upload it to their website
- 1x Arduino NANO, I can recommend a clone from SainSmart*
- 1x Adafruit PowerBoost 500C, official website
- 14x WS2812b adressable LEDs, my source
- 14x capacitors 100nF, my source
- 2x capacitors 47uF, my source
- 3x resistor 10K, possible source (not tested)*
- 1x resistor 330, possible source (not tested)*
- 1x 8 pin female pin header + 1x 8 pin male pin header, possible source (not tested)*
- 1x switch, my source
- 1x USB-B jack, my source
- 1x Samsung INR18650 battery, my source
- 1x 18650 battery holder, my source
- 1x magnet reed switch, my source
- 1x JST-PH cable, my source
- 2x button switch, my source
For the 3D-printed parts:
- PLA filament transparent, my source
- PLA filament in Living Coral, I can recommend products from SainSmart*
- TPU flexible fiament in Violet, I can recommend products from SainSmart*
All the rest:
- 3x screw 16x3mm, local store
- 4x screw 39x4mm, local store
- 2x cable ties, local store
- 5x small magnet, local store
- cable and heat shrink, local store
You will need the following tools:
Teachers! Did you use this instructable in your classroom?
Add a Teacher Note to share how you incorporated it into your lesson.
Step 1: Soldering the Electronics
I strongly recommend to use a PCB. You could of course also use perfboard, but that will be messy and considering the small price for PCBs these days, probaply not worth it. Start by soldering the WS28b LEDs to the PCB. ATTENTION: don't be silly like me and remember the polarity! You can see the label on the PCB and there is a little corner on the LED which corresponds with the ground. Double check it using the datasheet and a magnifying glass. Next component are the resistors. Start with R1 which is a data line
resistor with 330 ohm. C2-4 are pullup resistor with a resistance of 10K ohm
The next step are the capacitors. Start with C1 and solder in a 100nF capacitor. Solder the others until C14 to the PCB, but pay attention to C12: You will need to slightly bend it a little bit so that you are still able to acess the USB-port of the Arduino.
C15 and C16 are 47uF. Since they are polarized, pay special attention that you solder the ground pin to the corresponding hole in the PCB. It is labeld with a minus sign and the golden solder pin is a square.
Now you need to solder the female pin headers for the Powerboost. I will later explain why we don't solder it directly to the PCB. Last but not least we solder the Arduino NANO to the PCB. Push it all the way through and then solder each pin. After soldering, carefully trim off the remaining ends and make sure to wear safety glasses since they will jump around and make you blind or kill you!
Now it is time to solder the PowerBoost. Use a breadboard to hold the male pin headers and solder one pin after the other. You don't have to solder the USB-jack, but you can keep it for other projects. Now you can merge the PowerBoost with the PCB. We use the pin headers to make it higher, otherwise we would't be able to connect the battery.
The next step is the switch. Carefully solder two wires to the pins so that it is either on or off. Make sure that you don't burn it too long since they are a little bit sensitive. Cut the wires long enough (about 10cm) and use heat shrink to protect it from short circuits. The switch will be soldered later to the PCB, just like the other wires. Do not solder it on right now!
Do the same with the USB jack. I added some heat shrink to prevent it from short circuits.
Step 2: The 3D-printed Parts
For 3D printing the parts, I used my new Creality Ender 3, which can also be bought on SainSmart*. I really love it and considering the price it is absolute worth it in my opinion. I used PLA from SainSmart, it was sponsored from them. They call it Pro-3 series and I think it is pretty okay ONCE you find the good settings. It is a little more expensive than the alternatives, and it needs more testing than others. They send me the color called Living Coral, I don't really like its color and therefore I painted it, but you can of course choose your favorite color. Here's the link. I also used tranparent PLA to let the light shine trough, unfortunately SainSmart doesn't offer it.
For the buttons on the steering wheel I wanted to have a flexible top, so that it is waterproof. Therefore I used SainSmart TPU*, which is in my opinion a awesome material! I really love it and the price is almost unbeatable. It was also sponsored from SainSmart. I faced the problem that the single plastic lines won't stick very well to each other, but after experimenting with the right settings (slow, 210 degree and less retraction) it works quite good. Another problem is that flexible filament is hard to print with bowden tube printers. And again, violet is not the perfect color for my bike, but they do offer other colors.
If I would have to order filament again, I would choose an other PLA. Simply because it is not very special and the price is not "cheap". I dont recommend their PLA. But the TPU filament is absolute fantastic and I recommend to buy it, especially for cool vase mode prints.
I designed everything in Autodesk: Fusion 360, which is in my opinion an awesome CAD-software, even for younger makers like me. I also love that they do provide it FOR FREE to us makers. After a lot of prototypes, which can be partly seen on my Instagram channel, I finally can share the files with you. Just download the stl-files, if needed modify them, and slice it with your favorite slicer. I used Ultimaker: Cura for it because it is OpenSource and because it's free and easy to use. I usually print with small infill, mostly 10%, but with 3 perimeters. The layer height is 0,28mm since they don't have to look perfect.
For the multicolor print with transparent and colored PLA, there is a great little trick in Cura. You can click on the top bar on
Extensions -> Post progressing -> modify G-Code -> add a skript -> filament change -> layer
where you can enter the layer where the color change should appear. The same can be done with the flexible TPU and PLA. But the problem is that these two materials dont stick very well to each other and therefore I printed them seperately and glued them together.
After printing the main part for 7 hours, I destroyed the switch while mounting it. That's no problem because I simply printed an adapter for a new switch in TPU! That's easy and it looks even better (except the color).
Step 3: Uploading the Code
If you were careful in step 1 and you did solder C12 properly, you can simply upload the code. If you haven't, just like me, you can either:
- desolder it
- force the USB cable in
- use the ICSP port of the Arduino
I choose option 3 and used this Instructables written by Gautam1807 to program it (heres a tutorial by me: ELECTRONOOBS). It is quiet simple, but you can only do it in the Arduino IDE. After downloading the sketch from the top, you can upload it to your Arduino as always. If you don't know how, here's a great Instructables by user robogeekinc.
The code: (link), can also be downloaded from here
Step 4: Assembly
Now it is time to assemble everything. Start by pushing the PCB into the 3D-printed ring, and turn it a little bit. In my case it was really good because like this, the PCB was secured very stongly and the LED1 was on the top. If not, use a little bit of hot glue.
I took the battery case and screwed it in the corresponding hole using a 16x3mm screw. It should be mounted without damaging the battery. Then insert the switch in the adaptor by simply pushing it in and if necessary secure it with hot glue. Now you can merge the switch assembly with the case by insering it to the existing switch hole. Solder the two wires to the solder points on the PCB.
The USB jack was fitted in the hole and it stayed very well. Again, solder the wires to the PCB. Make sure to have the right polarity, which is marked on the PCB. Lastly solder four wires to the switch solder points and twist them a bit, then lead them trough the hole in the case. Connect the battery with the case and the cable with the PowerBoost.
After carefully screwing the main part together with 39x4mm screws, you can finally attach it to your bike. In my case it just clicked in, but I also secured it with two cable ties.
You need to run the wires from the back to the front of the bike. I used cable ties to attach a longer wire and used these screw terminals to connect the components. The turn activator is also mounted with cable ties. I don't have finished the drive detector, I will either use a magnet switch or a push button. I will update this Instructables once it is finished.
Step 5: Conclusion
The bike light project is finished now, after almost half a year of tinkering. I hope you liked this presentation of my project and maybe build your own.
There are some things which NEED to be improved in a second version. For example:
- add USB port and switch directly on the PCB
- Use a flat battery to make it more compact
- Make a sketch that detects when the battery is empty
- Build the drive detector
- use capacitive touch sensors
- make the case nicer
- overall a nicer look
Thank you again, SainSmart for giving me some of your products and a T-shirt for testing. Here is my honest opinion: I really like your TPU because it is a fair price and it works after some experimenting. The Ender 3 is not the perfect printer for TPU because of the bowden tube, but I guess that is with every TPU and bowden tube printer. The PLA is not really recommended by me. But if you want the perfect winding (which I dont conside the most important thing on a spool) then go for it. I don't really see the point why it is called PRO-Series, because it has nothing special. After a lot of experimenting, you get good results, but not way better ones than from other PLA. The Arduino is great, I dont have any problems with it. You will probably find cheaper options, but at SainSmart you get a USB cable, presoldered pins, the better USB chip and faster shipping. The only negative thing is (as Michael in the review section mentioned) is the documentation. It is compatible with Arduino, and there are many tutorials, but it might me a little hard for beginners, but for me no problem at all.
Thank you so much for reading my instrucables, if you liked it please tell me in the comments and vote for me in the assisitve tech challenge. Thank you!
This is an entry in the
Assistive Tech Contest