This project is aiming to build robot that can patrol alongside the road in pedestrian lanes. The AMD Hardware will take the main role in AI Detection and robot operation. I plan to use KR260 with the camera to Make an AI model to detect cars and make decisions. It KR260 will also control the movement of the robot with AI line tracking and a control motor to move the robot. also the decision of warning sound and light.
1.Hardware Of the Robot- High Level Design of Robot
The robot will have a 2-wheel differential drive. It uses lidar for mapping and navigating. It will use a depth camera for detection and tracking. The power of the robot will use 12V from SLA Battery. It will have 5 inch for interactive display.
- Wheel and motor
For wheel and motor that make the robot move. I use a differential drive system. I use a wiper motor with a 5-inch wheelset. It has good enough torque for robot movement and the price is not expensive. The problem is this motor does not have an encoder which is very important for the robot to have feedback to the system. I use an external Omron encoder which is quite easy to find in the market. Then I design a 3D print to attach the encoder and wheel together with the GT2 belt.
- Main Chassis
My main robot chassis uses a 20mmx20mm Aluminium profile. Connect together with the connector and connect the wheel set to it.
- Driving system
The electronics for driving motors. I use a dual-channel 10A dc motor driver. The motor driver board will connect to my MicroROS node controller. The encoder feedback was also sent to it. I design this board using STM32 microcontroller to handle Odometry and Command Velocity topics to control the robot. Actually I have been looking into AMD KR260 FPGA which can design and handle both motor pwm driving signal and encoder pulse counting but I need to learn quite a lot more as I think still quite hard for me who highschool student to understand in a short time. So maybe it will work out in the future but for now, I stick with STM32 as microROS node.
- microROS node
I designed an STM32F407 integrated with a USB Serial. This board provides PWM output for the motor driver, Encoder input for Wheel Odometry, GPIO port for the NeoPixel Led light strip. I use i2c MPU6050 for angular velocity feedback to ROS2 system on AMD KR260. This board interfaces to AMD KR260 board via USB-Serial bus.
- Display and Interface
I use the 5-inch display to display information and control ROS2. AMD KR260 does not have an HDMI Interface or Display Interface. It only has a Display Port. I found some projects on making use of FPGA to create HDMI interfaces but as for me I still have a lot more to learn. So I design to use another SBC like Raspberry pi use as a companion ROS slave computer. It will handle tasks like display interface and Human interface and responding. It connects to AMD KR260 with an On Robot WIFI Router.
- Lidar
For robot to navigation, I use Lowcost SLAMTEC RPLIDAR C1 as Lidar slam tools. It interfaces to AMD KR260 with a USB Interface. There are available software packages supporting ROS2 on SLAMTEC website which make it easier to integrate into ROS System.
- ROBOT Body
I design a robot body with Fusion360. Each part size not bigger than 230*230mm which allows printing with most normal 3D printers.
The robot will use ROS2 as the main software. I designed to use Ubuntu 22.04 as the main operating system as it seems to be easier to understand and more resource for student who are new to ROS like me.
- Install Ubuntu to AMD KR260
The installation process of Ubuntu 22.04 is quite straightforward as AMD has an image file on their website. At first, I used an SD Card 16GB that come with a KR260 box. However, after I install ROS2 and other software and components. The 16GB SDCard is full so I need to get a 64GB SD card and go through the install process again. So I recommend that the SD Card should be at least 32GB.
- Install PYNQ
After days of reading and searching, I found that the easy way to develop AI on AMD Kr260 is to use PINQ. as It can be used Python Language which I am more familiar . I found https://github.com/amd/Kria-RoboticsAI.git seems to very good start for me. So I gave it a try, and after several attempts, I was success in installing Ubuntu with PYNQ environment. There are quite a few edit on the installation process as some directory names have changed. So now I am ready to go for ROS2.
- Install ROS2
After installing PYNQ and the environment I install ROS2 System following the guide on installing ROS 2 Humble Hawksbill distribution on your Ubuntu 22.04 desktop of the KR260 target board.
- Install Lidar Package
- Install Navigation Package
- Communication With microROS Node
After setup other 3D party Package. Now I test my STM32F4 microROS node. I connect USB to AMD KR260 Board. I use the command Teleop to control Command Velocity Topic and let the Robot moving to follow the command. To check the encoder I just set Command Velocity to move forward at 0.1m/s constant. set up a test distance 1 m and measure the time take for robot to move should be 10 second. After fine adjustment of the encoder ratio now robot is now ready to move follow the command.
3. Write ROS ApplicationAfter the robot can communicate with Lidar and microROS board now I am ready to write ROS Application Package. A simple package that I create for the robot is "Move to goal" which makes the robot move to the position that I order it to go. Also now I start to look and study deeper on making ROSAI Application under KR260 board with PYNQ.
4. Future WorkI start this project with very little knowledge on ROS and AMD KR260 systems. I found that it needed quite a deep learning curve for me to study. Several months that try to learn and build this robot, trouble solving and researching. I quite happy that I can go this far, so far so good. I found that I will need to study more on AMD KR260 , VitisAI , PYNQ which is quite challenging for me.
I think this robot is about 60% in progress, It finished Low-level system. Integrate ROS and Sensor. Now I need to write a program and put use of AI on AMD KR260. I planning on try to customize ML DPU to KR260 to make model that can detect and tracking parents car. I used to work on Yolo and Tensor Flow Lite on my PC but to implement to AMD KR260 I still find quite challenging for me to get into and under stand it system.
So, I will keep working in to it and I will update this project as follow up progress.
After a long journey, It still a lot more to go on this project. I will continue working on this project as this will be my first big ROBOT project. Thank you for Reading and interest in my project. If any suggestions please feel free to comment. Sorry if my English not good. Thank You.
Comments
Please log in or sign up to comment.