Robots are tools that can ease the burden on humans. Robots can be controlled by humans directly, but actually robots can also make their own decisions if given an intelligent algorithm. The type of robot that is often used in school activities is a wheeled robot. A wheeled robot is a robot that moves by using wheels. The purpose of this project is to get a robot that can recognize lines. This project has been implemented and took approximately 3 days. This robot has been equipped with an infrared sensor of the TCRT5000
type. In the process, this sensor works based on the principle of light reflection obtained from the object which is then forwarded to the phototransistor to determine the output value. If the light reflection on a dark or black object is considered inadequate, the sensor module will provide a LOW
output, in which case the LED indicator will not light up. If the light reflection on a bright or white surface is considered adequate, the sensor module will provide a HIGH
output, in which case the LED indicator will light up. The benefit of making this project is none other than to add insight. The results showed that the system made can function properly.
Part | Description |
---|---|
Development Board | Raspberry Pi Pico |
Code Editor | Thonny IDE |
Bootloader | MicroPython UF2 |
Programming Language | MicroPython |
Packages | • machine (default) • utime (default) |
Actuators | Gear Motor / Motor DC (x2) |
Sensor | KR08200: 3 Way Line Tracking IR Sensor - Brand: Funduino (x1) |
Other Components | • Micro USB cable - USB type A (x1) • Micro USB cable - 2 pin JST (x1) • Jumper cable (1 set) • KCD11: Rocker Switch SPST (x1) • Li-ion battery 18650 (x2) • 2-Slot series battery holder (x1) • Robot wheels (x2) • Caster wheel (x1) • Motor driver L298N (x1) • Car robot frame (x1) • Spicer bolts (1 set) • Bolts plus (1 set) • Nuts (1 set) |
-
Thonny IDE
https://bit.ly/ThonnyIDE_Installer
-
MicroPython UF2
https://bit.ly/UF2_RPIpico_Bootloader
Block Diagram | Pictorial Diagram |
---|---|
Wiring |
---|
-
Upload the firmware
:-
Press and hold the
BOOTSEL
button on theRaspberry Pi Pico
board while connecting to the computer via amicro USB
cable. -
After the
Raspberry Pi Pico
is recognized by the computer (connected), then immediately release theBOOTSEL
button. -
When successfully connected, a new drive called
RPI-RP2
will open. -
Drag -> Drop
orCopy -> Paste
theMicroPython UF2
firmware file into theRPI-RP2
drive.
-
-
After the process is successful, the
RPI-RP2
drive will automatically close. -
In general, the firmware upload only needs to be done once when you first use the
Raspberry Pi Pico
board.
-
Open
Thonny IDE
first. -
Click
Tools
-> then selectOptions...
-> then select :•
Interpreter Menu
, then change the part :-
Interpreter
->MicroPython (Raspberry Pi Pico)
-
Port
->Board CDC @ COM...
-
Restart interpreter before running a script
->uncheck
•
Editor Menu
, then check all the options except:Indent with tab characters
. -
-
If the file view does not exist in
Thonny IDE
, then please click theView
-> section and selectFiles
to display it. -
Then look for a file called
main.py
in directory:Raspberry-Pi-Pico-based-Line-Follower-Robot/Src
. -
Right click on the file -> select
Upload to /
. -
Open the file
main.py
which is in theRaspberry Pi Pico
storage -> then clickRun current script (F5)
. -
Program code executed successfully -> sign:
%run -c $EDITOR_CONTENT
. -
If there is still a problem when uploading the program, then try to check the
interpreter
/port
/others
section.
-
Download and extract this repository.
-
Make sure you have the necessary electronic components.
-
Make sure your components are designed according to the diagram.
-
Configure your device according to the settings above.
-
Please enjoy [Done].
If this work is useful to you, then support this work as a form of appreciation to the author by clicking the ⭐Star
button at the top of the repository.
MIT License - Copyright © 2023 - Devan C. M. Wijaya, S.Kom
Permission is hereby granted without charge to any person obtaining a copy of this software and the software-related documentation files to deal in them without restriction, including without limitation the right to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons receiving the Software to be furnished therewith on the following terms:
The above copyright notice and this permission notice must accompany all copies or substantial portions of the Software.
IN ANY EVENT, THE AUTHOR OR COPYRIGHT HOLDER HEREIN RETAINS FULL OWNERSHIP RIGHTS. THE SOFTWARE IS PROVIDED AS IS, WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, THEREFORE IF ANY DAMAGE, LOSS, OR OTHERWISE ARISES FROM THE USE OR OTHER DEALINGS IN THE SOFTWARE, THE AUTHOR OR COPYRIGHT HOLDER SHALL NOT BE LIABLE, AS THE USE OF THE SOFTWARE IS NOT COMPELLED AT ALL, SO THE RISK IS YOUR OWN.