Viewing camera on ROS20. Install Docker on a Linux system1. Start ROS Wifi image transmission module ROS2 agentPublishing nodesTopic informationMessage typeTopic posting frequency2.ROS2 obtains camera image3.View images in RVIZ4.matters needing attention
# **If using a system provided by the data, skip this step**
sudo apt update
sudo apt install docker.io docker-compose
docker -v
Download and install Docker as shown in the picture
For example, in the above figure, my IP address is 192.168.2.100, and the configuration of the serial port is shown in the figure
After clicking send, there are two types of information to print, both of which are configured
xxxxxxxxxx
# If the virtual machine using the data runs the command directly
sh start_Camera_computer.sh
xxxxxxxxxx
# Not a virtual machine provided by the data
docker run -it --rm -v /dev:/dev -v /dev/shm:/dev/shm --privileged --net=host microros/micro-ros-agent:humble udp4 --port 9999 -v4
The successful entry result is shown in the figure:
There must be so much information to correctly activate the agent. Missing one may require manually powering off and resetting the ROS Wifi image transmission module
According to the proxy results in the above figure, the IP of the ROS Wifi image transmission module can be obtained as 192.168.2.114
Note: If using a virtual machine provided in the data, only refer to step 4
xxxxxxxxxx
mkdir -p ~/yahboomcar_ws/src
xxxxxxxxxx
colcon build
echo "source ~/yahboomcar_ws/install/setup.bash " >> ~/.bashrc
source ~/.bashrc
xxxxxxxxxx
ros2 run yahboom_esp32_camera sub_img
xrviz2 #rviz/rviz2