2. Setting Up Robotics SDK
This section describes how to set up the Robotics SDK on the Processor SDK Linux for Edge AI.
2.1. Requirements & Dependencies
2.1.2. Processor SDK Linux for Edge AI
The Robotics SDK requires the SD card image from Processor SDK Linux for Edge AI:
Link to Processor SDK Linux
Processor SDK Linux for TDA4VM (Version 9.0.0.X)
Processor SDK Linux for AM68A (Version 9.0.0.X)
Processor SDK Linux for AM69A (Version 9.0.0.X)
The SD card image contains Processor SDK Linux and libraries that are necessary for setting up the Robotics SDK environment.
2.1.3. Ubuntu PC
A Ubuntu PC is required for visualization of ROS topics published from the TI EdgeAI Starter Kit (SK) board. We have tested only with native x86_64 Ubuntu PCs and have not tested with any other Ubuntu systems: including Ubuntu virtual machines and Docker Desktop on Mac or Windows.
It is assumed that a matching ROS distro (ROS 2 Humble) is installed on the remote Ubuntu PC, either in the host Ubuntu filesystem natively or in a Docker container. In case you want to install ROS natively on the remote Ubuntu filesystem:
For ROS 2 Humble installation steps, please refer to this ROS 2 documentation.
We also provide Dockerfiles (
docker/Dockerfile.x86_64.humble) that can build and run on the remote Ubuntu PC for ROS 2 Humble, with detailed steps for setting up the Docker environment on the remote PC. For installation of Docker on the Ubuntu PC, the following links may be useful:
The Robotics SDK provides camera ROS nodes for ZED stereo camera, USB mono cameras (Logitech C270, C920, C922, and others), and CSI cameras including IMX219 and IMX390. All the demo applications can be tried out with a live camera as well as with a ROSBAG file that is provided with the SDK.
For configuration of a stereo camera, please see ros1/drivers/zed_capture/README.
For configuration of a USB mono camera, please see ros1/drivers/mono_capture/README.
For configuration of CSI cameras, please see this section of Processor SDK Linux documentation.
For GStreamer camera ROS node (USB cameras are also supported), please see ros2/drivers/gscam2/README_TI
2.2. Set Up Development Environment on the Target
Figure 1 shows the hardware setup and high-level installation steps on the target SK board and the Ubuntu PC. The target SK board and the remote Ubuntu PC are assumed to be connected on the same network through Ethernet or WiFi connectivity. For details on how to set up the WiFi on the SK board, please refer to this section of Edge AI documentation.
2.2.1. Build SD Card
From the Ubuntu PC, download the SD card image (
tisdk-edgeai-image-<platform>-evm.wic.xz) from Processor SDK Linux (using the links provided in Section 1.2).
Flash the downloaded image to an SD card (minimum 32GB, high-performance) using the Balena Etcher tool. For detailed instructions, please refer to this section.
The etcher image is created for 16 GB SD cards. If you are using a larger SD card, it is highly recommended to expand the root filesystem to use the full SD card capacity using the following steps on the Ubuntu PC.
# find the SD card device entry using lsblk (Eg: /dev/sdb) # use the following commands to expand the filesystem umount /dev/sdX1 umount /dev/sdX2 sudo parted -s /dev/sdX resizepart 2 '100%' sudo e2fsck -f /dev/sdX2 sudo resize2fs /dev/sdX2 # replace /dev/sdX in above commands with SD card device entry
2.2.2. Connect Remotely to the Target
To find the target IP address assigned to the EVM, use a serial port communications program (for example,
sudo minicom -D /dev/ttyUSBxwhere
/dev/ttyUSBxis the device for the UART serial port), log in with
rootaccount, and run
From a terminal on the PC, open an SSH session to connect remotely to the target:
user@pc:~$ ssh root@<target_IP_address>
It is recommended to use a static IP for the SK board to make ROS network setting easy.
2.2.3. Initial Setup for the Robotics SDK
18.104.22.168. On the SK Board
You can run the installation script on the target as follows:
root@am6x-sk:~$ cd /opt/edgeai-gst-apps/scripts root@am6x-sk:~$ source ./install_robotics_sdk.sh
This script takes care of:
Cloning the main GIT repository for Robotics SDK under
Setting up the folders for evaluating the Robotics SDK under
Downloading ROSBAG and other data files
Downloading several deep-learning models from the edge AI model zoo. You can also use the model downloader tool (please refer to this section of Edge AI documentation).
22.214.171.124. On the Remote Ubuntu PC
In a similar way, you can use a script to set up on the remote Ubuntu PC for visualization:
user@pc:~$ wget -O init_setup.sh https://git.ti.com/cgit/processor-sdk-vision/jacinto_ros_perception/plain/init_setup.sh user@pc:~$ source ./init_setup.sh REL.09.00.00
In a proxy network, in case the
wget command above does not work, you can try again with adding
--proxy off argument:
user@pc:~$ wget --proxy off -O init_setup.sh https://git.ti.com/cgit/processor-sdk-vision/jacinto_ros_perception/plain/init_setup.sh
2.2.4. Set Up Docker Environment on the Target
The Robotics SDK runs in a Docker container environment on the Processor SDK Linux. In the Robotics SDK Docker environment, ROS and necessary libraries and tools are installed.
First, following this link, please check that Docker and network work correctly on the target SK board.
The following section describes the Docker environment setup, details of building, and running apps under Docker. Please note that it will take several minutes to build the Docker image. The Docker image built can be listed with
Proxy Network: If the board running the Docker container is behind a proxy server, the default settings for downloading files and installing packages via
apt-get may not work, and proper settings for proxy should be established for building and running the SDK Docker image.
Docker Run: After “docker build” is completed, it is important to use
docker_run_rosX.sh script to start a Docker container, since the script includes all the necessary settings to leverage all the cores and hardware accelerators of the processor. Please note that
--rm argument by default. Just remove the
--rm argument in
docker_run_rosX.sh in case you want to do “docker commit” after exiting a Docker container. A short information about several useful Docker commands is provided in this link.