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

How to get the topics data from kinect?

asked 2013-01-09 17:53:40 -0500

sam gravatar image

updated 2016-10-24 08:59:00 -0500

ngrennan gravatar image

I use ubuntu12.04 64 bits with ROS fuerte.

I follow BagRecordingPlayback tutorial.

I run:

  roslaunch openni_launch openni.launch depth_registration:=true
  optirun rosrun rviz rviz

I set the frame to /camera_link and add point cloud2 section to visualize /camera/depth_registered/points topic but get nothing.

I try to figure out what happened.

I follow several link of kinect problems, and I find some thread also have the similar situations.

I couldn't find an exact solvable solutions.

Can anyone help me step by step to solve this problem?

Thank you very much~

=========================

When I run:

  sam@sam:~$ rosrun image_view disparity_view image:=/camera/depth_registered/disparity
  Inconsistency detected by ld.so: dl-close.c: 759: _dl_close: Assertion `map->l_init_called' failed!
  sam@sam:~$

It shows the window with /camera/depth_registered/disparity title but no image on it.

I check the lib version without problems:

  sam@sam:~$ apt-cache policy libopenni-dev 
  libopenni-dev:
    Installed: (none)
    Candidate: 1.5.4.0-3+precise1
    Version table:
       1.5.4.0-3+precise1 0
          500 http://packages.ros.org/ros/ubuntu/ precise/main amd64 Packages
  sam@sam:~$ apt-cache policy libopenni-sensor-primesense-dev 
  libopenni-sensor-primesense-dev:
    Installed: (none)
    Candidate: 5.1.0.41-2+precise1
    Version table:
       5.1.0.41-2+precise1 0
          500 http://packages.ros.org/ros/ubuntu/ precise/main amd64 Packages
  sam@sam:~$

My roslaunch output is this link.

When I run freenect, it shows:

  sam@sam:~$ roslaunch freenect_launch freenect-registered-xyzrgb.launch 
  ... logging to /home/sam/.ros/log/92195ade-5b27-11e2-b007-e0b9a5f829db/roslaunch-sam-23199.log
  Checking log directory for disk usage. This may take awhile.
  Press Ctrl-C to interrupt
  Done checking log file disk usage. Usage is <1GB.

  while processing /opt/ros/fuerte/stacks/freenect_stack/freenect_launch/launch/freenect.launch:
  while processing /opt/ros/fuerte/stacks/freenect_stack/freenect_launch/launch/examples/include/produce-xyzrgb.launch:
  Invalid roslaunch XML syntax: [Errno 2] No such file or directory: u'/opt/ros/fuerte/stacks/freenect_stack/freenect_launch/launch/examples/include/produce-xyzrgb.launch'
  sam@sam:~$

What happened?

========================== Before plugin kinect on usb port 2.0:

  sam@sam:~$ lsusb
  Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
  Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
  Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
  Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
  Bus 001 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
  Bus 002 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
  Bus 003 Device 003: ID 1a40:0101 Terminus Technology Inc. 4-Port HUB
  Bus 001 Device 005: ID 13d3:3362 IMC Networks 
  Bus 001 Device 004: ID 13d3:5710 IMC Networks 
  Bus 003 Device 004: ID 046d:c077 Logitech, Inc. 
  sam@sam:~$

After plugin kinect on usb port 2.0:

  sam@sam:~$ lsusb
  Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
  Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
  Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
  Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 ...
(more)
edit retag flag offensive close merge delete

Comments

Can you try this? rosrun image_view disparity_view image:=/camera/depth_registered/disparity

yigit gravatar image yigit  ( 2013-01-09 21:47:34 -0500 )edit

@sam: I've noticed 2 problems: First: You don't have the correct openni-packages installed. Notice when you run apt-cache policy it says none in front of installed. Second, you need to upgrade freenect_stack. The issue you've experienced has been fixed and updated debs released.

piyushk gravatar image piyushk  ( 2013-01-11 05:16:38 -0500 )edit

@sam: once you have the packages installed, installed should show the same thing as candidate.

piyushk gravatar image piyushk  ( 2013-01-11 05:18:01 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
3

answered 2013-01-09 23:34:36 -0500

I suspect you may have tried these already, but I've detailed all the problems I have faced in the past:

  • Your device may be plugged into a USB 3.0 port. If you only have USB 3.0 ports, see @MichaelH's answer in this thread
  • You may be using the older openni drivers. Check if you have the system packages libopenni-dev (v1.5.4) and libopenni-sensor-primesense-dev (v5.1.0) installed. If not, see @tfoote's email on how to upgrade here

Other things that might help solve the issue:

  • Output of your roslaunch command. It might be able to tell us if the openni driver did not load successfully
  • Does it work with depth_registered set to false?
  • As @yygyt suggested, can you view any of the images? Try viewing /camera/rgb/image_color and /camera/depth/image_raw in rviz or image_view.
  • Does the freenect based driver work? Try running the freenect-registered-xyzrgb.launch file
edit flag offensive delete link more

Comments

I once had problems with the depth-registration option of the old openni driver. I haven't had a chance to try the latest release though. @sam you may want to check out my experience http://answers.ros.org/question/46066/kinect-dynamic-reconfigure-does-not-work/#46450

yigit gravatar image yigit  ( 2013-01-10 00:31:00 -0500 )edit

/camera/rgb/image_color and /camera/depth/image_raw are both show nothing in rviz.

sam gravatar image sam  ( 2013-01-10 01:21:38 -0500 )edit

I have tried hg clone openni_launch and openni_camera and rosmake successfully, but it's not work also.

sam gravatar image sam  ( 2013-01-10 02:07:04 -0500 )edit

@sam If none of the recommendations work, try posting the output of lsusb and dmesg a few seconds after you plugin your kinect.

piyushk gravatar image piyushk  ( 2013-01-10 19:49:34 -0500 )edit

@sam and what about depth_registered topics (e.g. /camera/depth_registered/disparity). I think you forgot to mention them

yigit gravatar image yigit  ( 2013-01-10 20:09:27 -0500 )edit

I have edit my original post. And /camera/depth_registered/disparity is already have. It shows 'Inconsistency detected by ld.so: dl-close.c: 759: _dl_close: Assertion `map->l_init_called' failed!'. What can I do now? Thank you~

sam gravatar image sam  ( 2013-01-10 23:34:53 -0500 )edit

Have you tried using it without depth registration? I had issues with that here as well.

georgebrindeiro gravatar image georgebrindeiro  ( 2013-01-11 01:33:52 -0500 )edit

@sam: see my latest comment attached to your question.

piyushk gravatar image piyushk  ( 2013-01-11 05:17:07 -0500 )edit

Question Tools

Stats

Asked: 2013-01-09 17:53:40 -0500

Seen: 1,780 times

Last updated: Jan 10 '13