Blinkerlights - Traffic Indicator Lights for Urban Cyclists #phablabs

About: PHABLABS 4.0 is based on combining the World of Photonics (Science of light and light technologies) with the growing creative ecosystem of existing Fab Labs. The “Photonics Workshops” introduce a variety of ...

You ride a bike in traffic where cars are that have indicator lights. Why shouldn’t you?
Well, now you can. Increase your visibility by adding turn signals (LED-strips) to your backpack or a high-visibility jacket. With a buttonbox, that magnetically attaches to your bike’s handlebars, you can control the blinking of the LED-strips. Get instructed in the use of LED-strips, a microcontroller, a breadboard and basic programming. Convert the breadboarded circuit into a rugged, water-repellent, battery-powered LED-strip controller. You will make an add-on for backpacks for a cyclist which will work as a direction indicator, thus improving the safety of the cyclist. An extra option to the workshop is to attach their smartphone on the handlebar of their bike which will work as GPS and communicate with the microcontroller which controls the light sources.

Properties of this workshop:

Timeplanning: Total: 6h

1. Introduction to Arduino, building the circuit on breadboard & testing the program: 180 minutes
2. Soldering introduction, building & assembling the controller. Testing the final setup: 180 minutes

Target audience: 15-18+ years old

DISCLAIMER: By using this information you agree to be legally bound by these terms, which shall take effect immediately on your first use of the information. PHABLABS 4.0 consortium and its member organizations give no warranty that the provided information is accurate, up-to-date or complete. You are responsible for independently verifying the information. VUB cannot be held liable for any loss or damage that may arise directly or indirectly from the use of or reliance on the information and/or products provided. PHABLABS 4.0 consortium and its member organizations disclaim all responsibility to the maximum extent possible under applicable laws: All express or implied warranties in relation to the information and your use of it are excluded. All liability, including for negligence, to you arising directly or indirectly in connection with the information or from your use of it is excluded. This instruction is published under the Creative Commons licence CC-BY-NC.

Teacher Notes

Teachers! Did you use this instructable in your classroom?
Add a Teacher Note to share how you incorporated it into your lesson.

Step 1: Part List

Photonics parts:

*RGB LED ribbon (5V) + 3-pin connectors (photo 1&2)
*Orange LED 3mm (photo 3)

Other parts:

*ABS Black enclosure, 818-0505, http://benl.rs-online.com/web/b/hammond/ (photo 4)
*ABS small enclosure,513-5369, http://benl.rs-online.com/web/b/hammond/ (photo 5)
*Neodynium magnet 25mm (photo 6)
*2 Waterproof buttons (photo 7)
*1 switch (photo 8)
*1 potmeter 10K (photo 9)
*Resistor 470 Ohm
*Resistor 2.2 kOhm
*1 Feather HUZZAH (photo 10)
*1 PCB (Gerber files attached: BikeBlinkersCircuit_Gerber_NC_Drill) (photo 11)
*1 3,7V Lipo Battery with JST-PH connector (photo 12)
*2 pieces of 4-pin audio socket connector (photo 13)
*1 coiled 4-pin audio cable (photo 14)
*1 large soft steel washer
*1 3D printed part to hold the magnet (stl file attached: steeringblock1v2) (photo 15)

Tools (for example in Fab Labs):

*3D printer
*(Optional: Laser cutter)
*Drill press with center drill, 3mm drill and step drill
*Dremel
*Soldering iron

The photonics parts can be bought online: http://b-photonics.eu/en/photonics-toolkit/genera...

The bottom of the small enclosure is a 3D printed part, printed in black PLA. We recommend printing this ahead of time.

ATTENTION! The potentiometer is optional. With this potentiometer you can control several blinking programmes on the LED strips. But this is not necessary! Without potentiometer only the traffic light indicators will blink.

Depending on the installation of the potentiometer, the correct Arduino programme should be installed.
BikeBlinker01
BikeBlinker01_NoPot

Step 2: Breadboarding the Circuit

The circuit will be built and tested on a breadboard. This can be done in stages, as each stage allows the instructor to teach part of the circuit & the code.

Photo 1: Electronic scheme

As your circuit works on a breadboard, you can start with the PCB and the soldering part of the workshop.

Photo 2: PCB and Feather Huzzah on the PCB.

Photo 3: Electronics for the small enclosure.

Step 3: Preparing the ABS Enclosures

The large and small enclosure needs a number of holes. This can be done by a lasercutter, or you can do it yourselve manually with a drill/dremel.

Photo 1: Place of the holes in the small enclosure.

Photo 2: Place of the holes in the large enclosure.

The diameter of the holes are indicated. These can be drilled. The large enclosure also needs a hole for the switch. This hole is rectangular and can be sawn with a dremel. The large enclosure also needs a hole for the connector of the Feather Huzzah and another hole for the LED connectors. These can be sawn with a dremel.

Step 4: Getting Started Soldering...

ATTENTION! The potentiometer is optional. With this potentiometer you can control several blinking programmes on the LED strips. But this is not necessary! Without potentiometer only the traffic light indicators will blink.

Depending on the installation of the potentiometer, the correct Arduino programme should be installed. BikeBlinker01
BikeBlinker01_NoPot

Photo 1: Solder the 8cm-long solid-core wires onto the potmeter. Use red and black wire for the outside connections. Use another colour for the middle (signal) connection. Use shrink tube to insulate the connectors.

Photo 2: To practice your soldering skills you can also wire up the socket connectors. Use black wire to connect to the upper pin (later this will be connected to the GND). Use white wire to solder to the pin underneath. Use blue wires to solder to the outside connections.

Photo 3: Wire up the switch.

Step 5: Building the Small Controller Box

In the next steps you will build the small controller box. You will need the parts shown in photo 1.

The two water-repellent buttons (hole of 12mm) and the orange LED (hole of 3mm) needs to stick through the top of the small enclosure. Therefore you need to drill 3 holes. Use a pencil and ruler to indicate the holes on the right spot. Photo 2

The socket connector (hole of 7 mm) should be at the side of the box. Also indicate the hole on the right spot. Use drills of 3mm, 7 mm and 12 mm to make the holes. (photo 3&4)

Insert the buttons, the orange LED and the connector. Solder the connections and resistors according to the electrical scheme. (Photo 5&6)

When done soldering, you can close up the small enclosure with the 3D printed part. This part is designed to fit a bike handlebars and to contain a magnet. Screw the 3D printed part on top of the small enclosure and push the magnet in the hole. (Photo 7)

Step 6: Building the Large Controller Box

You need to drill 2 holes. One for the potentiometer (hole of 7mm) through the top of the large enclosure and one for the socket connector (hole of 7mm) at the side of the box. Also drill out the upright cylinders of the lid of the box. (Photo 1&2)

Glue the large washer into the large controller box. For this part you will need a prepared enclosure. You also need the large washer, 2-component epoxy glue & a mixing stick. Mix 2 equal parts of the epoxy. Glue the washer in the enclosure. Make sure it is flat, don’t use too much glue. Leave the glue to set for 15 minutes, then insulate the washer using Kapton tape.(Photo 3) Because of this washer you will able to snap the smaller box on the large box when you are not riding the bike. (Photo 4)

With the dremel you should cut out a square for the switch at the long side of the large enclosure and a hole for the charger of the HUZZAH and the LED connectors at the opposite side of the hole of the socket connector.

All electronic parts fit on the PCB. Mount the electronics board. You need:

-the Feather Huzzah board
-the pinholders
-the large enclosure
-the PCB

The board will sit inside the enclosure as shown in photo 5. As you can see, the protoboard does not quite fit. Cut out at least one hole for the screw (in the corner of the large enclosure) with a knife.

Next solder in the pinheaders in the Feather. So: add pinheaders to all pinout holes. The easy way to do this is to plug everything into a breadboard and solder from the top. (Photo 6)

Next, place the Feather on the PCB. There is only one way to solder the Feather correctly on top of the PCB. Turn the board over and solder in the pinheaders as shown in photo 7&8. Now use the side cutters to cut the pins sticking out of the bottom as flush as possible with the board.

Solder in the wiring & connections.

You will now connect all the parts to the PCB.

This is the most tricky step, as you need to make sure your wires are cut to the correct length to make everything fit inside neatly. Work slowly and do a lot of testfits over the course of the next steps.

On the right of the PCB, you will find two times: VCC, DAT and GND. On these holes, you have to solder the LED 3pin-connectors. The red wire (+5V) goes to VCC, the green wire (Dout) goes to DAT and the white wire (GND) goes to GND. Photo 9, 10 & 11

The DAT holes are connected to pin 14 and 15 on the Feather.

The switch needs a resistor of 2.2kOhm. Solder this resistor on the PCB. The resistor will pull the enable-pin of the microcontroller low when the switch is off. At the on position it will place 3.3V on the Enable pin. You can also use the X1 pin and a Ground pin for the switch, then you don’t need a resistor. But the symbols on the toggle switch will not be correct then. Photo 12&13

The switch should be soldered to X1 and X2. X1 is connected to both VCC and to +3V. X2 is con- nected via the resistor to the enable pin. Photo 14&15

Next, solder the audio connector to the PCB. Black goes to GND, White goes to D. Blue wires go to X1 and X2, which are connected to pin 4 and pin 5 on the Feather. (Doesn’t really matter which one is where, we can switch button assignment in software) Photo 16&17

OPTIONAL!

If you have some time left, you can solder the POTmeter to the PCB. You can then programme several programmes to the Feather, and depending how you turn the potmeter, you can lighten the blinkers, or a rainbow effect.... Photo 18

Last but not
least: wire in the battery.

The battery has the correct connector to be clicked into the Feather Huzzah.

IMPORTANT!

You have to use LiPo’s with built-in battery protection. The internal 3.3V regulator of the microcontroller board is not powerful enough to drive all LEDs, therefore the VCC pin of the LED strips is directly connected to the battery. Photo 19&20

That means that the built-in shift registers of the individually addressable LEDs will slowly empty the LiPo.

If you do not use it for a week or two, you will have to charge it via the USB port.

You can solve this problem by adding an extra buck-converter with enable pin. But that would be too complex for beginners in soldering workshops.

It is also important to switch off the power switch only when the lights are off. Since the microcontroller is off, the LEDs will keep one specific color mode (you want to keep R GB 0; 0; 0).

Cut off the legs below the PCB (photo 21) and put everything inside the large enclosure. (Photo 22-26)

Step 7: Connecting the Box and LED Strips to the Backpack/fluorescent Vest

Sew the lid of the large enclosure on top of your backpack or vest. Photo 1

Decide where the LEDs should come and how long the strips should be. Cut off pieces with the correct size. Photo 2

Solder the connectors to the LED strips. Attach pieces of velcro to the LED strips and on the correct places on your backpack/vest. Photo 3

Step 8: Programming Arduino

The PCB used in this workshop is not really an Arduino board, but a feather HUZZAH. To use this arduino progamme for this, you should first download additional info to be able to upload information on it.

Feather HUZZAH ESP8266: WiFi built-in battery charging for IoT on-the-go! You can find ‘How to’ install this via this link: https://learn.adafruit.com/adafruit-feather-huzzah-esp8266/using-arduino-ide

Depending on the installation of the potentiometer, the correct Arduino programme should be installed. BikeBlinker01: with potentiometer
BikeBlinker01_NoPot: without potmeter

If this is all done, you can open the file (‘bikeBlinker01’) attached. Connect the Feather Huzzah to your computer. Check via ‘tools’ if the correct board is selected:
Board: “Adafruit HUZZAH ESP8266”
Select the right port.
Then push the upload button (the arrow pointing to the right)
When it is succesfully uploaded, you can disconnect the feather huzzah and use the blinkers.

Arduino programme files + extra explanation: Photo 1-4

Step 9: End Result and Conclusions

Congratulations! You’re done! From now on, you can start safely cycle through traffic.

On the use of this controller:

-To charge the battery, plug the controller into a regular microUSB 5V phone charging cable & toggle the main switch on the controller to the ON position.

We like the charging feature on this board, but it is slow (100mA charge current). To fully charge the empty battery you will need to leave it plugged in overnight.

ABOUT PHABLABS 4.0 EUROPEAN PROJECT

PHABLABS 4.0 is a European project where two major trends are combined into one powerful and ambitious innovation pathway for digitization of European industry: On the one hand the growing awareness of photonics as an important innovation driver and a key enabling technology towards a better society, and on the other hand the exploding network of vibrant Fab Labs where next-generation practical skills-based learning using KETs is core but where photonics is currently lacking. www.PHABLABS.eu

This workshop was set up by the Brussels Photonics Team, Vrije Universiteit Brussels in close collaboration with Fablabfactory.

Be the First to Share

    Recommendations

    • CNC Contest

      CNC Contest
    • Make it Move

      Make it Move
    • Teacher Contest

      Teacher Contest

    Discussions