环境:主机macbook,虚拟机软件VirtualBox,虚拟机Ubuntu20,ros版本——noetic
在终端输入roslaunch usb_cam usb_cam-test.launch,摄像头能点亮,但跳出来的窗口是花屏
但用openCV能正常打开摄像头,不知道是不是ros usb_cam对虚拟机兼容性不好,请问道友们有没有解决方法或相关链接
终端具体信息如下:
~/catkin_ws/src/usb_cam/build$ roslaunch usb_cam usb_cam-test.launch
... logging to /home/erin/.ros/log/5c227e5a-0993-11ec-9a9f-89ce01692739/roslaunch-erin-VirtualBox-10335.log
Checking log directory for disk usage. This may take a while.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.
started roslaunch server http://erin-VirtualBox:41103/
SUMMARY
========
PARAMETERS
* /image_view/autosize: True
* /rosdistro: noetic
* /rosversion: 1.15.11
* /usb_cam/camera_frame_id: usb_cam
* /usb_cam/image_height: 480
* /usb_cam/image_width: 640
* /usb_cam/io_method: mmap
* /usb_cam/pixel_format: yuyv
* /usb_cam/video_device: /dev/video0
NODES
/
image_view (image_view/image_view)
usb_cam (usb_cam/usb_cam_node)
ROS_MASTER_URI=http://localhost:11311
process[usb_cam-1]: started with pid [10349]
process[image_view-2]: started with pid [10350]
[ INFO] [1630337617.736986359]: Initializing nodelet with 1 worker threads.
[ INFO] [1630337617.914545813]: Using transport "raw"
[ INFO] [1630337618.000285673]: using default calibration URL
[ INFO] [1630337618.008409458]: camera calibration URL: file:///home/erin/.ros/camera_info/head_camera.yaml
[ INFO] [1630337618.008519466]: Unable to open camera calibration file [/home/erin/.ros/camera_info/head_camera.yaml]
[ WARN] [1630337618.008573806]: Camera calibration file /home/erin/.ros/camera_info/head_camera.yaml not found.
[ INFO] [1630337618.008627093]: Starting 'head_camera' (/dev/video0) at 640x480 via mmap (yuyv) at 30 FPS
[ WARN] [1630337618.153641151]: unknown control 'white_balance_temperature_auto'
[ WARN] [1630337618.160093523]: unknown control 'focus_auto'
launch文件如下: