Social Distancing Warner (Sensor Stimulated LED Modification)

1,891

11

2

Introduction: Social Distancing Warner (Sensor Stimulated LED Modification)

This project is simply a modification of this awesome Instrutables project: https://www.instructables.com/id/Arduino-Distance...

Brief Introduction of The Original Project:

The device contains 6 LED lights bulbs of three different colors, red, yellow, and green. As an object moves closer to the LED, the LEDs will light up in order from green to yellow to red. There is also a speaker that increases its frequency as the object moves closer. As the LEDs switch phases (from one color to another), the speaker will turn up a notch in its frequency.

Modifications include:

- An extra LED of a different color

- A cardboard Case Surrounding The Board

Purpose of Modification:

- Since the 6 original LEDs are placed only for the user of the device to see, I figured I should put one for whoever is being sensed by the sensor to see. Therefore, I added a white LED at the front of the device that lights up when the red ones light up (meaning that the person is extremely close to the device). That person, upon seeing the white light will know to back off.

- The cardboard allows the device to be carried around. The cardboard case places the speaker on the side, one LED (white) and the sensor at the front, and all the other LEDs at the back. This design allows it to be more easily used.

Supplies

Arduino Leonardo (or Arduino Uno) x1

Large Piece of Cardboard x1

Breadboard x1

HC-SRO4 Ultrasonic Sensor x1

Buzzer x1

Green LEDs x2

Yellow LEDs x2

Red LEDs x2

White LED x1

330 ohm Resistors x8

Tape (Both Wide and Thin)

Long Ruler x1

Utility Knife x1

Screw x1

Penci

A lot of jumper wires (Both Types: two ends with pins, one end with pin and the other and without)

Step 1: Assembling the Board

This section is completely based on the original project. Information and illustration From: https://www.instructables.com/id/Arduino-Distance-Detector-with-a-Buzzer-and-LEDs/

Assemble The Components on The Bread Board Based on The Graphic Illustration Above

Verbal Instruction on The Jump Wire Connections:

Buzzer = Digital Write pin 3

(On Ultrasonic Sensor)

Echo = Digital Write pin 6

Trig = Digital Write pin 7

(LEDs From Right to Left)

Red LED1 = Digital Write pin 8

Red LED2 = Digital Write pin 9

Yellow LED3 = Digital Write pin 10

Yellow LED4 = Digital Write pin 11

Green LED5 = Digital Write pin 12

Green LED6 = Digital Write pin 13

***Please, Please, Please Note That This Arduino Design and The Graphic Illustration Are NOT ORIGINAL. I DID NOT Conceive of This Portion of The Project The original source is: https://www.instructables.com/id/Arduino-Distance-Detector-with-a-Buzzer-and-LEDs/

Step 2: LED Modification and Component Extension

Add The White LED on To The Bread Board

White LED = Digital Write pin 5

Extend all components with the jump wires with two different ends as shown in picture above. The end with a pin enters the bread board and the side with the hole connects whatever was on the bread board. If the LEDs are loose in the extension jump wires, you can secure it with the thinner tape.

Step 3: Creating the Cardboard Box.

Take your large piece cardboard and carve the shape of the outer outline shown in the picture with your utility knife. For the red lines marked on the images, you carve only "half". What do I mean by carving "half"? Well, notice how a piece of cardboard has two layers (as shown in the illustration above with two red lines). Cutting "half" meaning cutting through only one of the two layers. We are doing this because we will be folding at the red lines, and cutting half would weaken the structure and facilitate the fold without destroying the structure. The "half" cuts are also shown on one of the pictures above.

Step 4: Punch Some Holes

Punch cavities in the portions of cardboard shown above. First penetrate the cardboard with a screw. Then insert a pencil into the tiny hole and rotate while pushing the hole larger to the size of the pencil. Remember to create a hole for the energy supplying cable!

*****A mistake is shown in the picture and is corrected by the red markings. There should be 6 holes on the upper side and one on the top side.

Step 5: Secure the LEDs and Buzzer

Place the LEDs into the carved holes. It is most likely that the LEDs will fall out, so make sure you secure tape them on with the thin tape as shown above. It doesn't really matter how you stick it, just make sure they don't fall out too easily. I would suggest first sticking them together in a row then stick the row to the cardboard. For the buzzer, just stick it right on to the three holes punches on the side with the speaker side facing out.

Step 6: Assemble the Box

Fold the cardboard together and a rectangular box should form. Tape the box together with thicker tape. You can tape more layers if it's loose.

Step 7: Code

The assembly is done!!!!!!!

Here's the link to the code. Copy and paste it into your coding application and you're good to go!

Link to code: https://create.arduino.cc/editor/novembersix/068326c0-7f98-492c-aeed-db2e751748ba/preview

Step 8: Testing

As an object moves closer to the ultrasonic sensor, the buzzer's frequency would increase and the LEDs would light up in order from green to yellow to red and white. You can carry the box around by swapping your computer to a portable charger.

Video:

Be the First to Share

    Recommendations

    • Maps Challenge

      Maps Challenge
    • Fandom Contest

      Fandom Contest
    • Pets Challenge

      Pets Challenge

    2 Comments