WEBVTT

00:00.000 --> 00:03.000
Have you ever wondered about a farming robot?

00:03.000 --> 00:05.960
That can work in fields at night, avoid obstacles,

00:05.960 --> 00:07.520
follow lights for guidance,

00:07.520 --> 00:10.600
and still be controlled manually when needed.

00:10.600 --> 00:11.760
Welcome.

00:11.760 --> 00:13.800
In this video, we going to build

00:13.800 --> 00:15.720
night timing farming support robot

00:15.720 --> 00:19.040
using Arduino and an IR remote control.

00:19.040 --> 00:22.480
In this project, we are going to build a smart robot

00:22.480 --> 00:25.640
that can perform three different tasks.

00:25.640 --> 00:27.040
Obstacle avoidance.

00:27.040 --> 00:29.480
Where the robot automatically avoids obstacles

00:29.480 --> 00:32.000
in its path, light following,

00:32.000 --> 00:33.840
where the robot follows a light poles

00:33.840 --> 00:36.200
to navigate through the farm at night,

00:36.200 --> 00:39.160
and manual control, where we can fully control

00:39.160 --> 00:42.120
the robot using the IR remote.

00:42.120 --> 00:45.480
By combining automation with manual control,

00:45.480 --> 00:49.480
this robot becomes versatile, practical, and educational.

00:51.040 --> 00:52.840
The first and most important component

00:52.840 --> 00:55.440
of our project is the Arduino Uno.

00:55.440 --> 00:58.080
It is the brain of our project.

00:58.080 --> 01:00.360
The Arduino is a microcontroller board

01:00.360 --> 01:03.000
that allows us to connect and control

01:03.000 --> 01:06.280
different electronic components, all through programming.

01:07.520 --> 01:12.120
Our second component is the L298N motor driver.

01:12.120 --> 01:15.120
This component is used to control motors in our project.

01:16.680 --> 01:19.600
Our third component is the ultrasonic sensor,

01:19.600 --> 01:21.560
which measures the distance to obstacles

01:21.560 --> 01:23.880
and guides the robot to avoid collisions.

01:25.560 --> 01:28.360
Our next component is the servo motor.

01:28.360 --> 01:32.320
It rotates the front ultrasonic sensor left and right,

01:32.320 --> 01:34.640
allowing the robot to scan its surroundings

01:34.640 --> 01:36.160
and choose the safest path.

01:40.080 --> 01:44.120
The next component is a pair of DC geared motors with wheels.

01:44.120 --> 01:47.000
These motors drive the robot forward, backward,

01:47.000 --> 01:48.360
left and right.

01:50.040 --> 01:52.520
Now we have the robot car chassis,

01:52.520 --> 01:54.880
the base frame that holds everything together.

01:55.560 --> 01:57.960
It comes with a base plate, a top plate,

01:57.960 --> 02:02.320
spacers, and fiber mountings, all fixed with screws.

02:02.320 --> 02:04.240
At the front, it also has a holder

02:04.240 --> 02:05.880
for the ultrasonic sensor.

02:08.880 --> 02:13.480
Our next components are the IR remote and IR receiver.

02:13.480 --> 02:15.640
The remote sends commands to change modes,

02:15.640 --> 02:17.960
control movement, and adjust speed,

02:17.960 --> 02:19.880
while the receiver captures these signals

02:19.880 --> 02:21.200
for the robot to follow.

02:22.200 --> 02:25.200
We'll also use a battery pack with a switch

02:25.200 --> 02:26.800
to power the servos.

02:27.800 --> 02:31.600
Our next components are the two LDR sensors.

02:31.600 --> 02:33.800
These are used in light following mode.

02:33.800 --> 02:37.400
They detect light intensity and act as left and right sensors

02:37.400 --> 02:40.000
to guide the robot's movement toward a light source.

02:41.600 --> 02:45.600
And finally, jumper wires to connect everything together.

02:45.600 --> 02:49.000
Using all these components and some essential tools,

02:49.400 --> 02:52.400
we are going to build our night timing farming robot.

02:53.600 --> 02:55.800
Let us understand principles and applications

02:55.800 --> 02:57.600
of night timing farming robot.

02:58.800 --> 03:01.200
This is the night timing farming support robot

03:01.200 --> 03:03.200
with all its main components.

03:03.200 --> 03:07.200
From the ultrasonic sensors and LDR sensors in the front,

03:07.200 --> 03:11.200
to the Arduino, motor driver, and receiver on the chassis,

03:11.200 --> 03:14.200
each part works together to make the robot function.

03:14.200 --> 03:17.600
This night timing farming robot works in three different modes,

03:17.800 --> 03:21.400
obstacle avoidance, light following, and manual control.

03:22.200 --> 03:25.000
Now, by pressing one on the IR remote,

03:25.000 --> 03:28.000
we activate the first mode obstacle avoidance.

03:43.600 --> 03:44.800
With this ability,

03:44.800 --> 03:48.200
the robot avoids tools, irrigation pipes, walls,

03:48.200 --> 03:49.400
or moving animals.

03:50.400 --> 03:53.600
Now, by pressing key number two on the IR remote,

03:53.600 --> 03:56.600
we activate the second mode, light following.

03:57.200 --> 04:00.400
In this mode, the robot follows the row of light poles

04:00.400 --> 04:01.400
along the farm.

04:02.000 --> 04:04.200
Each pole acts as a guiding beacon.

04:04.800 --> 04:08.400
The two LDR sensors detect which side receives more light

04:08.400 --> 04:11.200
and the Arduino adjust the direction automatically.

04:11.800 --> 04:14.200
When both sensors detect equal light,

04:14.600 --> 04:18.000
the robot moves straight, following the illuminated path.

04:18.600 --> 04:20.800
This setup makes night farming easier,

04:20.800 --> 04:24.200
allowing the robot to inspect crops, monitor conditions,

04:24.200 --> 04:26.400
or carry items safely through the fields.

04:28.000 --> 04:31.000
Now, by pressing three on the IR remote,

04:31.000 --> 04:34.200
we activate the third mode, manual control.

04:44.800 --> 04:54.800
This mode is ideal for night tasks,

04:54.800 --> 04:57.800
like moving through narrow rows, carrying tools,

04:57.800 --> 05:00.400
or working where automation isn't suitable.

05:14.200 --> 05:32.400
Let us explore the core components of our night timing,

05:32.400 --> 05:33.400
farming support robot.

05:36.000 --> 05:37.200
The Arduino Uno.

05:40.400 --> 05:43.200
It reads input from the ultrasonic sensors,

05:43.200 --> 05:46.200
processes it, and sends output signals to the motors.

05:46.800 --> 05:49.800
We use code to make the Arduino perform these actions.

06:10.800 --> 06:12.000
And a reset button.

06:14.200 --> 06:23.600
This ultrasonic sensor helps the robot detect obstacles,

06:23.600 --> 06:26.600
just like how bats use sound to sense their surroundings.

06:27.400 --> 06:30.400
It sends out an ultrasonic pulse and waits for the sound

06:30.400 --> 06:32.200
to bounce back from an object.

06:32.800 --> 06:36.200
By calculating the time it takes for the one wave to return,

06:36.200 --> 06:39.200
the robot figures out how far away the object is.

06:39.600 --> 06:43.000
It uses basic formula, distance equals speed of sound,

06:43.000 --> 06:45.800
multiplied by time, and divided by two.

06:48.400 --> 06:50.600
The motor driver acts like a power manager

06:50.600 --> 06:52.600
between the Arduino and the motors.

06:53.400 --> 06:55.600
The Arduino sends control signals,

06:55.600 --> 06:58.800
but those signals aren't strong enough to run motors directly.

06:59.600 --> 07:02.000
So, the motor driver boosts the control signals

07:02.000 --> 07:04.000
and sends them to the DC motors.

07:05.000 --> 07:11.000
The L298N motor driver includes the main L298N IC,

07:11.000 --> 07:14.000
which controls motor direction and power.

07:14.600 --> 07:17.800
It has terminal blocks for motor and power connections,

07:18.400 --> 07:21.200
input pins for signals from the Arduino,

07:21.200 --> 07:23.800
and enable pins for speed control.

07:25.000 --> 07:27.200
A built-in heat sink prevents the chip

07:27.200 --> 07:29.400
from overheating during operation.

07:34.200 --> 07:40.200
We use the servo to rotate the ultrasonic sensor side to side.

07:40.200 --> 07:43.200
This way, the robot can scan both left and right

07:43.200 --> 07:46.200
before making a decision about which direction to move.

07:47.200 --> 07:52.200
An IR receiver module and IR remote work together

07:52.200 --> 07:55.200
to enable wireless control of the robot.

07:55.200 --> 07:58.200
We use the servo to rotate the ultrasonic sensor side to side.

07:58.200 --> 08:01.200
This way, the robot can scan both left and right

08:01.200 --> 08:03.400
to enable wireless control of the robot.

08:04.200 --> 08:08.400
The remote uses an IR LED to send coded infrared light.

08:09.000 --> 08:13.000
The receiver with its photo diode sensor detects infrared light

08:13.000 --> 08:15.600
and converts them into electrical signals.

08:16.200 --> 08:19.000
Each button on the remote has a unique signal pattern.

08:19.600 --> 08:22.000
The Arduino reads these unique signals

08:22.000 --> 08:24.200
and carries out the command accordingly.

08:25.800 --> 08:28.600
This LDR sensor helps the robot detect light

08:28.600 --> 08:30.400
using changes in resistance.

08:30.800 --> 08:33.000
Just like how automatic street lights turn on

08:33.000 --> 08:35.600
when it gets dark and turn off when it's bright.

08:36.400 --> 08:40.600
The LDR sensor responds to the brightness of surrounding light.

08:41.000 --> 08:44.000
As more light falls on it, the resistance decreases,

08:44.000 --> 08:46.000
allowing more current to flow.

08:47.000 --> 08:50.000
When there's less light, the resistance increases,

08:50.000 --> 08:52.000
and the current flows more slowly.

08:54.400 --> 08:58.000
Now, let's build the nighttimeing farming support robot.

08:58.200 --> 09:00.800
Begin by assembling all the required components.

09:02.200 --> 09:05.200
This LDR sends wires to each of the motor terminals.

09:05.200 --> 09:06.600
Using changes in resistance.

09:06.600 --> 09:08.200
Just for negative.

09:09.000 --> 09:11.200
Make sure the solder joints are strong and clean

09:11.200 --> 09:14.200
to avoid any loose connections during operation.

09:15.200 --> 09:17.600
We begin by preparing the bottom chassis plate.

09:18.200 --> 09:21.400
First, attach the DC motors on both sides,

09:21.400 --> 09:24.800
using motor brackets, screws, and hexagonal nuts.

09:25.400 --> 09:27.400
Make sure the wheels are facing outward

09:27.600 --> 09:30.400
and that both motors are lined in a straight line.

09:30.400 --> 09:33.600
Tighten the screws just enough to hold the motors firmly

09:33.600 --> 09:35.600
but without bending the plastic plate.

09:37.200 --> 09:40.400
Next, fix the free wheel at the front of the chassis.

09:40.400 --> 09:43.000
The free wheel helps balance the robot,

09:43.000 --> 09:46.000
allowing it to roll smoothly in all directions.

09:46.000 --> 09:48.400
Position it carefully at the center

09:48.400 --> 09:51.000
so the robot does not tilt while moving.

09:52.400 --> 09:55.800
Now, attach the wheels to the motor shafts.

09:55.800 --> 09:58.200
Slide each wheel onto the shaft

09:58.200 --> 10:01.200
and secure it with a small screw if provided.

10:01.200 --> 10:04.400
Rotate the wheels gently to check if they move freely

10:04.400 --> 10:05.600
without wobbling.

10:07.400 --> 10:09.600
Once the motors and free wheel are fixed,

10:09.600 --> 10:12.000
place the spacers above the bottom plate.

10:12.000 --> 10:14.800
Align the top chassis plate over the spacers

10:14.800 --> 10:17.200
and tighten the screws and nuts.

10:17.200 --> 10:19.200
This creates strong two-layer body

10:19.200 --> 10:21.200
for our nighttimeing farming robot.

10:22.200 --> 10:26.200
Next, mount the L298N motor driver

10:26.200 --> 10:28.200
at the back center of the chassis.

10:28.200 --> 10:30.200
Then place the Arduino Uno board

10:30.200 --> 10:32.200
at the center for easy wiring.

10:35.200 --> 10:39.200
Connect the DC motors to the L298N motor driver

10:39.200 --> 10:42.200
with the left motor wire to out one and out two

10:42.200 --> 10:46.200
and the right motor wire to out three and out four.

10:46.200 --> 10:51.200
Make the connections using jumper wires as shown.

10:51.200 --> 10:55.200
Use the pin diagram for reference.

10:55.200 --> 10:58.200
Take a red jumper wire as the common positive line

10:58.200 --> 11:02.200
and connect to the VCC pins of the left LDR sensor,

11:02.200 --> 11:05.200
right LDR sensor, ultrasonic sensor,

11:05.200 --> 11:07.200
and the servo motor.

11:07.200 --> 11:11.200
Then, take a black jumper wire as the common ground line

11:11.200 --> 11:15.200
and connect it to the GND pins of all these components.

11:16.200 --> 11:20.200
Connect the VCC from all the components

11:20.200 --> 11:23.200
to the five volt pin of the motor driver

11:23.200 --> 11:25.200
and the GND from all the components

11:25.200 --> 11:28.200
to the GND pin of the motor driver.

11:30.200 --> 11:33.200
Fix the IR receiver at the front of the chassis,

11:33.200 --> 11:36.200
so it has a clear line of sight to the remote.

11:36.200 --> 11:39.200
Now, connect the positive and the negative pin

11:39.200 --> 11:43.200
of the IR receiver to the Arduino's five volt pin

11:43.200 --> 11:45.200
and GND pin.

11:46.200 --> 11:48.200
Now, power the Arduino

11:48.200 --> 11:53.200
by connecting the Arduino's VIN and GND pins.

11:54.200 --> 11:59.200
To the five V and GND ports of the L298N motor driver.

12:01.200 --> 12:04.200
Take the trig and echo pins of the ultrasonic sensor

12:04.200 --> 12:08.200
and connect them carefully to the A0 and A1 pins

12:08.200 --> 12:09.200
on the Arduino,

12:09.200 --> 12:11.200
making sure the wires are secure

12:11.200 --> 12:14.200
and properly placed just as shown in the diagram.

12:27.200 --> 12:31.200
Now, take the signal wire of the servo motor

12:31.200 --> 12:34.200
and connect it to digital pin three on the Arduino.

12:34.200 --> 12:36.200
Make sure the connection is firm

12:36.200 --> 12:39.200
so the servo can receive signals correctly.

12:42.200 --> 12:45.200
Finally, connect the motor driver to the Arduino.

12:45.200 --> 12:49.200
ENA goes to pin five in one to pin ten,

12:49.200 --> 12:51.200
in two to pin nine,

12:51.200 --> 12:54.200
in three to pin eight in four to pin seven,

12:54.200 --> 12:56.200
and ENB to pin six.

12:56.200 --> 12:59.200
This allows the Arduino to control the motors,

12:59.200 --> 13:01.200
both speed and direction.

13:11.200 --> 13:21.200
Mount the lithium ion battery

13:21.200 --> 13:23.200
and the power switch on the chassis.

13:23.200 --> 13:26.200
Fix the battery with double-sided tape

13:26.200 --> 13:28.200
so it stays firmly in place.

13:28.200 --> 13:30.200
Next, connect the black wire

13:30.200 --> 13:32.200
from the negative terminal of the battery

13:32.200 --> 13:37.200
to the GND pin on the L298N motor driver.

13:38.200 --> 13:40.200
Then, connect the red wire

13:40.200 --> 13:42.200
from the positive terminal of the battery

13:42.200 --> 13:44.200
to one side of the power switch

13:44.200 --> 13:46.200
and connect the other side of the switch

13:46.200 --> 13:51.200
to the 12-volt input pin on the L298N motor driver.

13:52.200 --> 13:55.200
Now, all components are connected.

13:55.200 --> 13:58.200
The night-timing farming robot is ready for programming

13:58.200 --> 13:59.200
and testing.

14:06.200 --> 14:08.200
First, connect the Arduino Uno to your laptop

14:08.200 --> 14:10.200
using a USB cable.

14:10.200 --> 14:13.200
This allows you to upload the code.

14:13.200 --> 14:16.200
Open the Arduino IDE on your computer.

14:16.200 --> 14:17.200
Go to file.

14:17.200 --> 14:22.200
Open and select your night-timing farming robot code.

14:22.200 --> 14:24.200
Next, open the tools menu,

14:24.200 --> 14:26.200
go to library manager,

14:26.200 --> 14:28.200
search for the IR remote in library,

14:28.200 --> 14:30.200
and install it.

14:30.200 --> 14:32.200
Then, under tools,

14:32.200 --> 14:35.200
select board and choose Arduino Uno.

14:35.200 --> 14:37.200
After that, go to tools, port,

14:37.200 --> 14:41.200
and select the correct COM port for your device.

14:41.200 --> 14:43.200
Now, click the verify button

14:43.200 --> 14:45.200
to check the code for any errors.

14:51.200 --> 14:53.200
After a few seconds,

14:53.200 --> 14:54.200
you'll see done uploading

14:54.200 --> 14:56.200
at the bottom of the screen,

14:56.200 --> 14:58.200
confirming a successful upload.

14:59.200 --> 15:00.200
After that,

15:00.200 --> 15:03.200
you can safely disconnect your laptop from the Arduino.

15:06.200 --> 15:08.200
In this testing,

15:08.200 --> 15:10.200
we are going to see the three modes

15:10.200 --> 15:12.200
of our night-timing farming support robot.

15:12.200 --> 15:15.200
Each mode is designed to perform a unique task,

15:15.200 --> 15:17.200
making the robot versatile

15:17.200 --> 15:19.200
for night-time farming operations.

15:19.200 --> 15:22.200
By pressing key number one on the remote,

15:22.200 --> 15:25.200
we activate obstacle avoidance mode.

15:25.200 --> 15:28.200
The robot uses its ultrasonic sensor,

15:28.200 --> 15:30.200
mounted on a rotating servo motor,

15:30.200 --> 15:32.200
to scan the path ahead.

15:32.200 --> 15:33.200
As it moves forward,

15:33.200 --> 15:36.200
it keeps checking the distance to obstacles.

15:36.200 --> 15:38.200
The moment something is detected,

15:38.200 --> 15:40.200
the Arduino processes the signal

15:40.200 --> 15:42.200
and decides the safest turn.

15:42.200 --> 15:44.200
This allows the robot to avoid tools,

15:44.200 --> 15:47.200
irrigation lines, walls, or animals,

15:47.200 --> 15:50.200
ensuring smooth navigation in the field at night.

15:56.200 --> 15:58.200
By pressing key number two,

15:58.200 --> 16:00.200
we activate light following mode.

16:00.200 --> 16:04.200
Here, the robot uses its two LDR sensors

16:04.200 --> 16:06.200
to detect the direction of light.

16:06.200 --> 16:08.200
When light is stronger on the left,

16:08.200 --> 16:10.200
the robot turns left.

16:10.200 --> 16:12.200
When light is stronger on the right,

16:12.200 --> 16:13.200
it turns right.

16:13.200 --> 16:15.200
When both sensors detect balanced light,

16:15.200 --> 16:17.200
the robot moves straight.

16:17.200 --> 16:19.200
This enables the robot to follow

16:19.200 --> 16:21.200
artificial lights or portable lamps

16:21.200 --> 16:23.200
for guidance during night-time operations.

16:23.200 --> 16:25.200
By pressing key number three,

16:25.200 --> 16:28.200
we activate manual control mode.

16:29.200 --> 16:31.200
In this mode, the robot is operated

16:31.200 --> 16:33.200
directly using the IR remote

16:33.200 --> 16:35.200
and its onboard receiver.

16:35.200 --> 16:37.200
By pressing different buttons,

16:37.200 --> 16:40.200
the user can move the robot forward,

16:40.200 --> 16:42.200
backward, left, or right,

16:42.200 --> 16:44.200
and even stop it when required.

16:44.200 --> 16:47.200
This mode gives full control to the operator,

16:47.200 --> 16:49.200
making it ideal for testing,

16:49.200 --> 16:51.200
handling delicate seedlings,

16:51.200 --> 16:55.200
or performing tasks where automation cannot be applied.

16:55.200 --> 16:56.200
And with that,

16:56.200 --> 16:59.200
our nighttime farming support robot demonstration

16:59.200 --> 17:00.200
comes to an end.

17:00.200 --> 17:03.200
The robot is now ready for practical use

17:03.200 --> 17:05.200
and nighttime farming operations.

