Introduction: Myopia Prevention Machine

This is a machine is made for the kids, some of the parents might worry their children are to close to the screen, and they will be myopia. So when the kids are using the machine and to close to it, the machine's light will flash and have sound, so the kids will know they are to close, they need to go backward.

Step 1: Prepare What You Need.

1. Ultrasonic sensor

2.Arduino speaker

3.LED (I use red)

4.wire

Step 2: Wiring

1.Ultrasonic sensor

VCC to 5V

TRIG to D6

ECHO to D7

GND to GND

2.Arduino speaker

+ to D6

- to GND

3.LED

+ to D12

- to GND

Step 3: Coding

Step 4:

Now we don't need to worry about your kids is being to close to the screen.