Using the Kinect sensor to view objects in 3D

The Kinect sensor is a flat, black box that sits on a small platform when placed on a table or shelf near the television you're using with your Xbox 360. This device has the following three sensors that we can use for vision and robotics tasks:

  • A color VGA video camera to see the world in color
  • A depth sensor, which is an infrared projector and a monochrome CMOS sensor working together, to see objects in 3D
  • A multiarray microphone that is used to isolate the voices of the players from the noise in the room.
Kinect

In ROS, we are going to use two of these sensors: the RGB camera and the depth sensor. In the latest version of ROS, you can even use three.

Before we start using it, we need to install the packages and drivers. Use the following command lines to install them:

    $ sudo apt-get install ros-kinetic-openni-camera ros-kinetickinetic-openni-launch
    $ rosstack profile && rospack profile
  

Once the packages and drivers are installed, plug in the Kinect sensor, and we will run the nodes to start using it. In a shell, start roscore. In another shell, run the following command lines:

    $ rosrun openni_camera openni_node
    $ roslaunch openni_launch openni.launch
  

If everything goes well, you will not see any error messages.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.144.29.148