ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

kinect 2 not working with ROS

asked 2017-03-10 01:19:15 -0600

vcdanda gravatar image

Hi, I have a problem to use kinect2 in my ROS and look for lots of ways to configure that but still cannot. Firstly, I follow the instructions from:

This link is the kinect driver in linux. It seems that everything works fine except

sudo dpkg -i debs/{libva,i965}*deb; sudo apt-get install -f

it tells me that it doesn't contain libva and i965 directory, and fails.

I used another way to install them:

sudo apt-get install libva-dev libjpeg-dev

I skipped this step, and followed the instruction to the end:


And this gives me four images which includes depth image and RGB image. However, I noticed that, when I executed this command, the output in the screen shows:

jimmy@eaibot:~/libfreenect2/bin$ ./Protonect Version: 0.2.0

Environment variables: LOGFILE=<protonect.log>

Usage: ./Protonect [-gpu=<id>] [gl | cl | clkde | cuda | cudakde | cpu] [<device serial="">]

    [-noviewer] [-norgb | -no

depth] [-help] [-version]

    [-frames <number of frames to process>]

To pause and unpause: pkill -USR1 Protonect

[Info] [Freenect2Impl] enumerating devices...

[Info] [Freenect2Impl] 13 usb devices connected

[Info] [Freenect2Impl] found valid Kinect v2 @4:9 with serial 002305464947

[Info] [Freenec

t2Impl] found 1 devices

libva info: VA-API version 0.35.0

libva info: va_getDriverName() returns 1

libva error: va_getDriverName() failed with operation failed,driver_name=i965

[Error] [VaapiRgbPacketProcessorImpl] vaInitialize(display, &major_ver, &minor_ver): operation failed

[Info] [Freenec

t2DeviceImpl] opening...

[Info] [Freenect2DeviceImpl] transfer pool sizes rgb: 2016384 ir: 608*33792

[Info] [Freenect2DeviceImpl] opened

[Info] [Freenect2DeviceImpl] starting...

[Debug] [Freenect2DeviceImpl] status 0x090000: 9729

[Debug] [Freenect2DeviceImpl] status 0x090000: 9731

[Info] [Freenect2DeviceImpl] submitting rgb transfers...

[Info] [Freenect2DeviceImpl] submitting depth transfers...

[Info] [Freenect2DeviceImpl] started

device serial: 002305464947

device fi

rmware: 4.0.3911.0

[Debug] [DepthPacketStreamParser] not all subsequences received 0

[Debug] [DepthPacketStreamParser] not all subsequences received 1008

[Debug] [DepthPacketStreamParser] skipping depth packet

[Debug] [DepthPacketStreamParser] skipping depth packet

[Info] [DepthPa

cketStreamParser] 2 packets were lost

[Debug] [DepthPacketStreamParser] skipping depth packet

[Info] [DepthPacketStreamParser] 1 packets were lost

[Debug] [DepthPacketStreamParser] skipping depth packet

[Debug] [DepthPacketStreamParser] skipping depth packet

[Debug] [DepthPacketStreamParser] skipping depth packet

[Debug] [DepthPacketStreamParser] skipping depth packet

^C[Info] [Freenect2DeviceImpl] stopping...

[Info] [Freenect2DeviceImpl] canceling rgb transfers...

[Info] [Freenect2DeviceImpl] canceling depth transfers...

[Info] [Freenect2DeviceImpl] stopped

[Info] [Freenect2DeviceImpl] closing...

[Info] [Freene

ct2DeviceImpl] releasing usb interfaces...

[Info] [Freenect2DeviceImpl] deallocating usb transfer pools...

[Info] [Freenect2DeviceImpl] closing usb device...

[Info] [Freenect2DeviceImpl] closed

[Info] [Freenect2DeviceImpl] closing...

[Info] [Freenect2DeviceImpl] already closed, doing nothing

From here, it shows there's some problem with the libva, however, I don't understand what the reminders mean. I used to be happy with the image and continue to work on the ROS. and the ROS results turn to be fairly disappointing!

I found a kinect ROS driver which is called iai-kinect2:

And it fails when I run

roslaunch kinect2_bridge kinect2_bridge.launch

This is the main problem.(I want to show you the overall message from the screen, but sorry, I don't know how.) And it shows me no message and always shows some problems:

[Info] [OpenCLDepthPacketProcessorImpl] building OpenCL ... (more)

edit retag flag offensive close merge delete


The system tells me there's something wrong with the opencl. I will tell you the progress later. Anyone who has met the same problem are welcome to share their experience.

vcdanda gravatar image vcdanda  ( 2017-03-10 21:52:17 -0600 )edit

Hi, Did you solve your problem ? I have the same problem,Can you help me ? Thank you very much!

wangshuailpp gravatar image wangshuailpp  ( 2017-06-21 22:39:24 -0600 )edit

I have a similar problem though I am running this package kinect2_tracker, and on launching roslaunch kinect2_tracker tracker.launch I get,

libva info: VA-API version 0.39.4
libva info: va_getDriverName() returns -1
libva error: va_getDriverName()
Harsh2308 gravatar image Harsh2308  ( 2018-10-30 16:24:52 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2017-04-19 08:53:27 -0600

Kami gravatar image

If it is really a opencl problem the why don't you try to run it without opencl at first? maybe this works: roslaunch kinect2_bridge kinect2_bridge.launch depth_method:=cpu

edit flag offensive delete link more

Question Tools



Asked: 2017-03-10 01:19:15 -0600

Seen: 2,355 times

Last updated: Mar 10 '17