ros-drivers/usb_cam

ros-drivers/usb_cam
Code
Issues 46
Pull requests 18

Segmentation fault (core dumped) #108
Open
arsessoft opened this issue on 8 Dec 2018 · 1 comment
Comments
@arsessoft
arsessoft commented on 8 Dec 2018

nikan@nikan-Inspiron-N5110:/Desktop$ rosparam set usb_cam/image_width 1920
nikan@nikan-Inspiron-N5110:/Desktop$ rosparam set usb_cam/image_height 1080
nikan@nikan-Inspiron-N5110:/Desktop$ rosparam set usb_cam/framerate 30
nikan@nikan-Inspiron-N5110:/Desktop$ rosparam set usb_cam/pixel_format yuyv
nikan@nikan-Inspiron-N5110:~/Desktop$ rosrun usb_cam usb_cam_node
[ INFO] [1544234089.395576612]: using default calibration URL
[ INFO] [1544234089.395658790]: camera calibration URL: file:///home/nikan/.ros/camera_info/head_camera.yaml
[ INFO] [1544234089.396566843]: Starting 'head_camera' (/dev/video0) at 1920x1080 via mmap (yuyv) at 30 FPS
[ WARN] [1544234089.544784752]: unknown control 'white_balance_temperature_auto'

[ WARN] [1544234089.552276396]: unknown control 'focus_auto'

Segmentation fault (core dumped)

Hi, my good friends. I was justified with the err. Please guide me to solve the problem

thx …
@trixr4kdz
trixr4kdz commented on 12 Jan

@arsessoft Let me see if I can help you out.

Can you type v4l2-ctl -d /dev/video0 --list-formats-ext on your terminal and comment here what the output is?

For example, my webcam only supports these resolutions with the corresponding pixel formats and frame rates:

$ v4l2-ctl -d /dev/video0 --list-formats-ext
ioctl: VIDIOC_ENUM_FMT
	Index       : 0
	Type        : Video Capture
	Pixel Format: 'YUYV'
	Name        : YUYV 4:2:2
		Size: Discrete 640x480
			Interval: Discrete 0.033s (30.000 fps)
		Size: Discrete 176x144
			Interval: Discrete 0.033s (30.000 fps)
		Size: Discrete 320x240
			Interval: Discrete 0.033s (30.000 fps)
		Size: Discrete 352x288
			Interval: Discrete 0.033s (30.000 fps)
		Size: Discrete 640x400
			Interval: Discrete 0.033s (30.000 fps)
		Size: Discrete 1280x720
			Interval: Discrete 0.133s (7.500 fps)
Index       : 1
	Type        : Video Capture
	Pixel Format: 'MJPG' (compressed)
	Name        : Motion-JPEG
		Size: Discrete 640x480
			Interval: Discrete 0.033s (30.000 fps)
		Size: Discrete 176x144
			Interval: Discrete 0.033s (30.000 fps)
		Size: Discrete 320x240
			Interval: Discrete 0.033s (30.000 fps)
		Size: Discrete 352x288
			Interval: Discrete 0.033s (30.000 fps)
		Size: Discrete 640x400
			Interval: Discrete 0.033s (30.000 fps)
		Size: Discrete 1280x720
			Interval: Discrete 0.033s (30.000 fps)

I think the reason you’re getting a Segmentation fault is because you were using a camera configuration that isn’t supported by the particular camera you were trying to use. In my case, if I were to use my camera for a YUYV pixel format, I can only go with a max resolution of 1280x720 at 30fps. If I want to choose a lower resolution, I’d have to go with 640x400 at 30fps since that’s what is supported.

In your case, I would check if you can use 1920x1080 for YUYV pixel format

Hope this helps!

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值