Install third party libraries and run a basic ROS2 application
At this point, third party libraries can be installed using apt-get. Use the following steps to install SSH and ROS2 and get a basic ROS2 application running.
- Install ssh:
c:\>adb shell
#apt-get install openssh-server
#echo "PermitRootLogin yes" >> /etc/ssh/sshd_config
#/etc/init.d/ssh restart - Log into QRB5165 using ssh. The default credentials are,
User name: root
Password: oelinux123 - Install locales, usbutils, git, bc:
c:\>adb shell
#apt-get install usbutils git bc
#apt-get -y install locales - Following these instructions to install ROS2 dashing (or any) version.
c:\>adb shell
#
#locale-gen en_US en_US.UTF-8
#update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8
#export LANG=en_US.UTF-8
#apt update && apt install curl gnupg2 lsb-release
#apt-key adv --keyserver keyserver.ubuntu.com --recv-keys F42ED6FBAB17C654
#sh -c 'echo "deb [arch=amd64,arm64] http://packages.ros.org/ros2/ubuntu `lsb_release -cs` main" > /etc/apt/sources.list.d/ros2-latest.list'
#apt install ros-dashing-desktop
#apt install python3-argcomplete
#apt install python3-colcon-common-extensions - Test if the ROS2 publish/subscribe mechanism is working.
- On one terminal, test the publish mechanism.
c:\>adb shell
#source /opt/ros/dashing/setup.bash
#ros2 run demo_nodes_cpp talker - On a second terminal, test the subscribe mechanism.
c:\>adb shell
#source /opt/ros/dashing/setup.bash
#ros2 run demo_nodes_py listener
The talker should say that it is publishing messages and the listener should say that it heard those messages. This verifies both the C++ and Python APIs are working properly. ROS2 is now up and running. - On one terminal, test the publish mechanism.