Introduction: Make the Decision! (Mask Machine)

In 2020, the COVID-19 spread all over the world, everyone now needs to wear a mask when they go out. Wearing a mask used to be an easy thing to do, but if a mask becomes essentials (just like the clothes you need to wear every day), then the style of mask you choose would be important. However, some of the people who can't choose things wisely would need some help. This mask machine would spend you only 1 second to choose the mask you're going to wear today! The only thing you need to do is to press the button and found the LED that has lighted. This machine would be used for people who had a hard time when they are making decisions about masks every day. (It can also change the mask to different items)!

Swipe down to know more about this project, and you can try to make it by yourself!

It's easy and fun.

Step 1: Prepare the Materials

Arduino button X 1

Arduino wire with female to male X 10

Arduino wire with male and male X 9

Arduino LED X 5

Arduino Uno X 1

Arduino Breadboard X 1

Arduino USB line X 1

Arduino Potentiometer 2.6V X 5

Arduino Potentiometer 4.0V X 1

Mask X 5

A place to charge your USB or a device that has a place to charge USB on it X 1

Step 2: Set Up for the Uno

1. Prepare all the materials

2. Put 1 of the wire from + to 5V and put one wire from - to GND

3. Put wire to both of the holes on the button, place the Potentiometer (4.0V) beside the button wire, put one wire to + and another wire on the same role with the Potentiometer.

4. Place another wire at the same role with the button(with the potentiometer) and put another head to D2.

5. Place the LED on the breadboard(I did it with wire because I can put out the LED to another place) and place one side of the potentiometer in the same line with the right head of the LED.

6. Place a wire from another head of the potentiometer and place the wire to -.

7. Place another wire to form the left head of the LED to D7-D11.

8. Repeat steps 5-6 until there are 5 LEDs.

9. Check if you put all the wires in the same place.

10. Place the USB line to the Arduino Uno and change it to a USB hole with energy

Step 3: Arduino Code

This is the code of this project

https://create.arduino.cc/editor/vanessafang/7eb23...

Code:

int _light ;

void setup(){ // put your setup code here, to run once: pinMode( 2 , INPUT); // sets the digital pin as input 按按鈕 }

void loop(){ // put your main code here, to run repeatedly: _light = random( 7 , 11 ) ;/隨機燈泡發亮 if (digitalRead( 2 )) { pinMode( _light , OUTPUT); // sets the digital pin as output digitalWrite( _light , HIGH ); // sets the digital pin on/off delay( 1000 ); // waits a few milliseconds } digitalWrite( _light , LOW ); // sets the digital pin on/off }

Step 4: Step 4: Test and Decoration

After you finish making your Arduino project, you can decorate your box.

These are the video of my project.