Kira represents our state-of-the-art robotics solution that competed in the 2023 France Robotic Cup, helping us achieve a commendable 5th place finish. Developed in C++, it is implemented on a Raspberry Pi 4 and communicates with an Arduino Nano through the I2C interface. Kira is designed to efficiently manage all of the robot's movements and actions.
- First, ensure that the
Remote - SSH
extension is installed in your Visual Studio Code environment. - Open Visual Studio Code, press
F1
to open the command palette, typeRemote-SSH: Connect to Host...
, and hitEnter
. - When prompted, enter the Raspberry Pi's IP address
[email protected]
and press Enter. - Next, input the password for authentication. The password is noted in the blackboard.
Upon successful connection, open the integrated terminal in Visual Studio Code and navigate to the project directory with the following command:
cd Documents/Kira/src/cpp
.
If there have been modifications in the Arduino's code, upload these changes by running:
./Kira -u
.
Note that the arduino code should be uploaded only if you change something in the arduino's code.
To bring the robot to life, use:
./Kira
.
In order to halt the robot, issue:
./Kira -s
.
To inspect the Arduino's serial port output, utilize the following command:
sudo screen /dev/ttyUSB0 9600
.
Before you attempt to upload the Arduino's code, it's essential to ensure the /dev/tty/USB0 port isn't being used. This can be checked by executing:
sudo fuser /dev/ttyUSB0
.
If the port is occupied, terminate the process using:
sudo kill <pid>
.
Replace <pid>
with the relevant process identifier, which can be obtained using the sudo fuser /dev/ttyUSB0
command.
After each restart of the robot, it happens that the ports /dev/ttyUSB
of the arduino and the lidar are reversed, to resolve this, simply change the file LidarController.cpp
the port number, either /dev/ttyUSB0
or /dev/ttyUSB1
, and to change if necessary to upload the arduino code, the variable named ARDUINO_PORT
in the file Main.cpp
If you encounter any roadblocks or have queries, do not hesitate to contact me, Iliasse MOUFLIH, on any of my social media platforms.