International Gate Using Arduino Mega

by jean_m11 in Circuits > Arduino

64 Views, 1 Favorites, 0 Comments

International Gate Using Arduino Mega

WhatsApp Image 2024-10-13 at 17.35.39_b60254ce.jpg

This is my project that I made for the “Microcontrollers” Contest. My project consists of an International Gate, with weighing to ensure that the truck can pass safely over the country-to-country asphalt road. I am 13 years old and am studying at Collège des Soeurs de Ste-Therese - Lebanon

Supplies

Components.jpg

1x Arduino Mega (if using LCD) or Arduino Uno (if using I2C LCD)

2x Servo Motor

1x HX711 Load Cell Amplifier

1x Load Cell

1x Green LED

1x RED LED

1x Buzzer

1x Ultrasonic Sensor

2x 220Ω Resistors

1x IR Proximity Obstacle Sensor

Wiring

I’m using an Arduino Mega

Connect the LCD to the Arduino:

VSS to GND

VDD to 5V

RS to 8

E to 9

D4 to 4

D5 to 5

D6 to 6

D7 to 7

*It is used to show valuable information like instructions and current weight

Load Cell Connections to HX711:

  1. Red Wire to E+
  2. Black Wire to E-
  3. White Wire to A-
  4. Green Wire to A+

*It is used to measure the truck's weight

HX711 Connections to Arduino:

  1. VCC to 5V
  2. GND to GND
  3. DT to pin 30
  4. SCK to pin 31

*It is used to connect the Load Cell to the Arduino

Green LED to pin 22

Red LED to pin 23

Buzzer to pin 26

Servo 1 to enter the testing to pin A1

Servo 2 to exit testing to pin A2

Ultrasonic Sensor to enter testing:

  1. Trig to 24
  2. Echo to 25

IR Proximity Sensor to pin 32

Arduino Code

Screenshot 2024-10-13 173103.png

To upload this code, we will copy it onto the “Arduino IDE” and choose the board and click on the “Upload” button, symbolized by an arrow.

Downloads

How It Works

The truck driver steps next to the first ultrasonic sensor, and the servo acting as a gate to scale testing opens. The lcd inputs “Step on Scale” and the scale starts weighing. If the truck triggers the IR Proximity Sensor, if the weight exceeds 1T, the driver is not allowed to pass and the servo2 opens so the driver can go back and the red LED turns on, and if it is less than 1T, the servo opens and the green LED is turned on.

Why Is It Used

Sometimes trucks need to pass between countries, and there is a road, to prevent the damaging of this road, I made a system to check the truck weight and see if it is allowed to pass without damage. This project can help reduce maintenance costs due to less breaking, and promote a greener life: The asphalt isn’t breaking, so its materials stay intact and we don’t need to put new materials.

Working Video