RB5 drone streaming from different cameras
-
While following instructions provided here
https://docs.modalai.com/Qualcomm-Flight-RB5-sdk-camera-server/
and here
https://docs.modalai.com/Qualcomm-Flight-RB5-streamer/
we managed to get low resolution streaming from camera 3 (Front Hi-res).-
Is it possible to get higher resolution camera stream (for example FullHD)?
-
How to get stream from other cameras, for example camera 2 (Front Tracking)?
sh-4.4# rb5-camera-server-configure Would you like to enable the camera service? This will start all cameras in a background process Selecting yes will start the service, no will disable the service 1) yes 2) no #? 1
Trying to run systemctl status rb5-camera-server@2 provided strange error/warning:
root@qrb5165-rb5:~# systemctl status rb5-camera-server@2 ● rb5-camera-server@2.service - "rb5-camera-server-2" Loaded: loaded (/usr/bin/rb5-camera-server; indirect; vendor preset: enabled) Active: active (running) since Fri 2022-04-08 18:04:24 CEST; 2min 39s ago Main PID: 2681 (rb5-camera-serv) Tasks: 4 (limit: 4915) CGroup: /system.slice/system-rb5\x2dcamera\x2dserver.slice/rb5-camera-server@2.service └─2681 /usr/bin/rb5-camera-server -c 2 Apr 08 18:04:24 qrb5165-rb5 systemd[1]: Started "rb5-camera-server-2". Apr 08 18:04:24 qrb5165-rb5 rb5-camera-server[2681]: gbm_create_device(156): Info: backend name is: msm_drm Apr 08 18:04:24 qrb5165-rb5 systemd[1]: /etc/systemd/system/rb5-camera-server@.service:12: Unknown lvalue 'After' in section 'Service' Apr 08 18:04:24 qrb5165-rb5 systemd[1]: /etc/systemd/system/rb5-camera-server@.service:13: Unknown lvalue 'Requires' in section 'Service' Apr 08 18:04:25 qrb5165-rb5 systemd[1]: /etc/systemd/system/rb5-camera-server@.service:12: Unknown lvalue 'After' in section 'Service' Apr 08 18:04:25 qrb5165-rb5 systemd[1]: /etc/systemd/system/rb5-camera-server@.service:13: Unknown lvalue 'Requires' in section 'Service' Apr 08 18:04:27 qrb5165-rb5 systemd[1]: /etc/systemd/system/rb5-camera-server@.service:12: Unknown lvalue 'After' in section 'Service' Apr 08 18:04:27 qrb5165-rb5 systemd[1]: /etc/systemd/system/rb5-camera-server@.service:13: Unknown lvalue 'Requires' in section 'Service' Apr 08 18:04:28 qrb5165-rb5 systemd[1]: /etc/systemd/system/rb5-camera-server@.service:12: Unknown lvalue 'After' in section 'Service' Apr 08 18:04:28 qrb5165-rb5 systemd[1]: /etc/systemd/system/rb5-camera-server@.service:13: Unknown lvalue 'Requires' in section 'Service'
Could you advise how to get stream from cam2? Thanks!
-
-
@MJ said in RB5 drone streaming from different cameras:
Tracking
Hello,
At the moment the rb5-streamer only streams video at 640x480 at 30fps. In order to achieve a different resolution, a custom gstreamer implementation will have to be used. The rb5-streamer is based off of the code found here.
In order to get streams from other cameras, through rb5-streamer, begin by disabling the camera server for the corresponding camera you'd like to use, and start a new rb5-streamer instance using the
-c
flag to select the camera index. So for the tracking camera:systemctl stop rb5-camera-server@2 systemctl disable rb5-camera-server@2 rb5-streamer -c 2
A reboot may be required after stopping and disabling the service
you'll then be able to access the stream at rtsp://VEHICLES_IP:8554/camera2
Regarding the weird
systemctl status rb5-camera-server@2
warning messages, I don't believe I've seen those warning messages show up before. Were theAfter
andRequires
fields modified in the service file? These are the appropriate values in case it was modified:After=qmmf-server.service Requires=qmmf-server.service
-
I am having the same problem. I have tried to stop, disable camera server 2, and power cycled the rb5. when I am trying to run "rb5-streamer -c 2" it is giving me a server error, so I have used the following commands to restart camera 2.
systemctl enable rb5-camera-server@2
systemctl restart rb5-camera-server@2But still no luck. I am only able to view camera 3.
Any help will be appreciated!
-
I'm not sure if you still have this problem, but if you know ROS, you can stream the cameras on your computer by configuring the drone to have the ROS master on your computer. First follow the steps at this link to setup ROS on RB5. https://docs.modalai.com/setup-ros-on-voxl-2/
Then you can set the ROS master to be on your computer by opening ~/.bashrc on the RB5 drone, and entering these lines in the file:
export ROS_MASTER_URI=http://{PC_IP_ADDRESS}:11311/ export ROS_HOSTNAME={RB5_DRONE_IP}
PC_IP_ADDRESS can be obtained from ipconfig on your computer. RB5_DRONE_IP is the one you use to ssh into it.
Then on the drone:source ~/.bashrc
On your computer execute:
roscore Rviz
On the drone execute:
roslaunch voxl_mpa_to_ros voxl_mpa_to_ros.launch
You will then be able to view the camera display topics from voxl_mpa_to_ros on your computer. You can stream them on Rviz, and you can create ROS nodes to subscribe to these topics for whatever computer vision application you develop. Hope this helps.