Introduction: Arduino LED Sensor

original source:

This is a simple way of creating an Arduino LED Sensor. I created this project because of the pandemic. I have had a thought to create a soap dispenser for our school restroom. This will decrease the chance of the Coronavirus pandemic from spreading since people are not pressing for soap. I hope this project will give some inspirations for our school to build dispensers in the restroom!

Step 1: Step 1: Materials

  • Arduino Uno
  • Ultrasonic Sensor (HC-SR04).
  • Mini-BreadBoard
  • 1 Kohm Resistor
  • Jumpers
  • Red LED
  • Cardboard
  • Tape
  • Newspaper

Step 2: Step 2: Connect the Components

First of all, 5V and GND have to be connected to the breadboard. Second of all, the digital pin has to be connected correctly. Third of all, the LED light, the sensor, and the receptor need to be in the right place too.

Step 3: Step3: Code