How to connect Kinect to Raspberry Pi 2 or 3 with ROS

  Переглядів 117,001

Robotics Weekends

Robotics Weekends

6 років тому

Today's episode #8 is about using Kinect with ROS on Raspberry Pi 2 or 3.
Kinect is one of the most popular source of PointClouds - array of points with 3D coordinates information.
It has proprietary connector - actually it's USB+12V bus, and needs adapter for PC connection
Despite that Kinect is bigger than ASUS Xtion, it has also tilt motor, microphone array, accelerometer and better support from ROS community
PointClouds can be converted to LaserScan - array of range sensor data withing some angle range. It looks like lidar data, but not in 360 degrees. Laserscan information can be used for SLAM - map building, obstacle avoidance, etc...
Video transcript can be found here: roboticsweekends.blogspot.com/...
Links:
Launch file Gist: gist.github.com/Andrew-rw/7a8...
Rviz view files: gist.github.com/Andrew-rw/df1...
Freenect ROS wiki: wiki.ros.org/freenect_launch
Video transcript: roboticsweekends.blogspot.com/...

КОМЕНТАРІ: 115
@valeeeeeaaeeeeeeeeee
@valeeeeeaaeeeeeeeeee 3 роки тому
Came for the point cloud stayed for the sick beat
@yohanchristian2988
@yohanchristian2988 4 роки тому
do we need to install ubuntu on the rasberry pi as well? or just plug the ethernet cable directly? if i want to connect the rasberry pi through wifi is it still possible to view the image through the computer? I am sorry i am really new to raspberry pi and ros and confused what do i need to install on raspberry pi for this kind of projects.
@c2h7
@c2h7 3 роки тому
Thanks for the great tutorial! I'm new to ROS, can the depth image also be transformed to several laserscans at different heights, to detect smaller or hanging obstacles? Or is there a 3d laserscan option?
@RoboticsWeekends
@RoboticsWeekends 3 роки тому
Thank you. You can run several instances of depthimage_to_laserscan, and set scan_height property for every instance at different levels
@GhostJC777
@GhostJC777 6 років тому
Hi, just wanted find out how to power the kinect using the raspberry pi 3 as a master? Can the adapter be plugged straight into the Pi to power the kinect? Also is it possible to use the tilt motors on the kinect through the pi autonomously? Last question is can the kinect be used just as a camera for visual recognition, or is it recommended to use a normal webcam for this purpose?
@RoboticsWeekends
@RoboticsWeekends 6 років тому
Hi. Besides standard USB connection, Kinect requires 12V power. You can use any 12V ac adapter or Kinect 360 USB adapter. You can find wiring of Kinect cable in my videos. Freenect driver supports tilt motor but only for 1414 model. Looks like others also can work through downgrading firmware while initialization. For more info please refer to libfreenect readme. Kinect 360 has not the best vga camera. It is 0.3 MPixel with bad colors. If you want to get good textures for scanned 3d object, I recommend to use a separate camera.
@BilalKhan-rm8qk
@BilalKhan-rm8qk 6 років тому
Very interesting. Can you please tell which one you have used in the video? Raspberry Pi 2 or Pi 3?
@RoboticsWeekends
@RoboticsWeekends 6 років тому
Thank you. In the video is Raspberry Pi 2. But on Raspberry Pi 3 every step will be the same
@tarekalnema5383
@tarekalnema5383 3 роки тому
Hello Mr. Robtics weekends, I have one question. I am doing my project and it includes Pi, a depth camera, and AR smart glasses. Could you please help to know which AR smart glasses I can use to work with a raspberry pi and Kinect camera??
@RoboticsWeekends
@RoboticsWeekends 3 роки тому
Hi, unfortunately I have no any experience in AR smart glasses.
@_kudos8093
@_kudos8093 2 роки тому
I want to make a mobile 3d scanner with the Raspberry Pi 4, and the xBox 360 Kinect sensor. Any advice? Liked & subbed !
@RoboticsWeekends
@RoboticsWeekends 2 роки тому
Hi, from hardware perspective I'd recommend to check out the article on Medium how to make Kinect to be powered by USB only: link.medium.com/L9vCHfirFhb
@leang2157
@leang2157 6 років тому
Scott Boy show more of this?
@bandrew8040
@bandrew8040 6 років тому
Nice music
@shanecustom
@shanecustom 5 років тому
hey i got this error when trying to roslaunch vidsrv laserscan.launch [laserscan.launch] is neither a launch file in package [vidsrv] nor is [vidsrv] a launch file name I already created and write the node description from Gist but error still persist. Please help tq
@waimak7507
@waimak7507 3 роки тому
Hi Robotics Weekends, I dont have a rasperri pi but I want to try this out on my laptop (connected to the Kinect 360) running a Virtual Box VM (Ubuntu 16.04), will this work? I'm crashing my head into alot of brick walls trying to get it work like yours ... thanks
@RoboticsWeekends
@RoboticsWeekends 3 роки тому
Hello. Yes it will work, but not sure how virtualbox will handle kinect
@FireHart100
@FireHart100 4 роки тому
can you use this software for windows im not talking about the pi programs im talking about the rviz
@RoboticsWeekends
@RoboticsWeekends 4 роки тому
There is a possibility to install ros on Windows, but I have never tried that: wiki.ros.org/Installation/Windows
@shakkashakk1195
@shakkashakk1195 4 роки тому
So, i installed ROS and freenect normaly through sudo apt install, but now i dont know exactly how to utilize a custom .launch file and where exactly where to put it, as i dont have any catkin workspace or anything. I got Kinect to work with the Pi and visualize it through RVIZ on a Notebook, but i just get 1 frame each 3 seconds. I'm running on a RPI 3B+. Is there any way to reduce the point cloud count so the pi doesnt take that long? My idea is to have a robot map a room and im thinking of using rtabmap for this, but when i try to run the default test, it gives me an error about not receiving data in 5 seconds or something, so rviz doesnt show anything when running that. Well, i've ran into a lot of problems and my ROS knowledge doesnt keep up with those.
@RoboticsWeekends
@RoboticsWeekends 4 роки тому
Try to reduce the poincloud density. You can do it using rqt_reconfigure tool
@shakkashakk1195
@shakkashakk1195 4 роки тому
@@RoboticsWeekends I fixed all the problems with the launch files and etc. The thing about reducing the depth sensor resolution is not possible with the freenect driver, only in Openni. Freenect only supports two modes for each camera_mode and depth_mode. Openni offers more options and a lower resolution but it never detects my kinect no matter what i do. Well, it's sad but the only way i find is to upgrade to a more powerful SBC
@atharvajadhav8598
@atharvajadhav8598 5 років тому
what kind of data does kinect send? is it digital ?if yes how many bits and is serially or parallely sent?
@mrnic3
@mrnic3 3 роки тому
universal serial bus should give it away. openkinect.org/wiki/Protocol_Documentation
@Zaraza36063
@Zaraza36063 6 років тому
Botland? Are you from Poland?
@RoboticsWeekends
@RoboticsWeekends 6 років тому
Yep:)
@poorya1103
@poorya1103 6 років тому
hey man really good stuff but can you give a step by step on how to do this only on raspberry pi. i mean radpberry pi be the master and slave both. i get that you said somthing about changing a variable when asked the exact question. but its vague for me man. i searched every where. can you help me out? not a video maybe a step by step config? or any help?
@RoboticsWeekends
@RoboticsWeekends 6 років тому
Hi. It is pretty simple - just use RPi's local IP address as a value for ROS_IP and ROS_MASTER_URI. BTW these variable have such values by default. So you just can skip setting of these variables.
@poorya1103
@poorya1103 6 років тому
Robotics Weekends tnx man
@stacadypu458
@stacadypu458 5 років тому
which OS is RPI using in video rasbian or ubuntu?
@RoboticsWeekends
@RoboticsWeekends 5 років тому
I'm using Ubuntu. With Ubuntu I don't need to build ROS from sources and just use standard apt repository
@daveyjonesjr.8878
@daveyjonesjr.8878 4 роки тому
@@RoboticsWeekends It would have been good to point this out in the video - to save people the headache of reimaging their SD cards with ubuntu
@iyadsalameh1989
@iyadsalameh1989 3 роки тому
does it have to be connected with ethernet cable or can i connect with wifi ?
@RoboticsWeekends
@RoboticsWeekends 3 роки тому
It doesn't matter. But via ethernet you will get better data rate, because of wider bandwidth
@adventurer_omi
@adventurer_omi 5 років тому
hello..i want information for rasberry pi software for programming kinect,and from where i start to learn this programing?? i want to develop kinect to recognize my motion and action please help
@RoboticsWeekends
@RoboticsWeekends 5 років тому
Hi. Please refer to freenect documentation. This is an opensource library for kinect.
@adventurer_omi
@adventurer_omi 5 років тому
Thnk u..
@Kadeshy
@Kadeshy 6 років тому
does it work on Orange Pi Zero?
@RoboticsWeekends
@RoboticsWeekends 6 років тому
It should work on any board with Ubuntu installed.
@MrRammorales
@MrRammorales 4 роки тому
Hello, just a simple question, is this tutorial applicable to Raspberry Pi 4? Thank you!
@RoboticsWeekends
@RoboticsWeekends 4 роки тому
Hi. The only thing I can say for sure - result will be the same on any hardware with Ubuntu 16.04 -18.04. I've got Raspberry Pi 4 a couple days ago and going to install Ubuntu with ROS on it. I will keep you updated on my results.
@MrRammorales
@MrRammorales 4 роки тому
Robotics Weekends thank you! I Will be waiting for your update ☺️
@RoboticsWeekends
@RoboticsWeekends 4 роки тому
Update: I confirm - it works on RPi4 without any issues.
@MrRammorales
@MrRammorales 4 роки тому
Robotics Weekends Thank you very much! I just ordered Rasp Pi 4 for our thesis. Your tutorial will be very helpful!
@GIBBEHGaming
@GIBBEHGaming 4 роки тому
Hi, I’m interested in using solely the cameras for a project of mine. Do you or anyone you know, know of any way to pin out the ir array and the ir receiver of the Kinect in order to utilize it over Arduino or pi
@davidbatty6500
@davidbatty6500 4 роки тому
brandonsg123 if using the pi just connect via usb it’s much simpler than trying to pin out the ir array
@GIBBEHGaming
@GIBBEHGaming 4 роки тому
David Batty I’m trying to remove the camera and array from the housing in order to put it into my own project
@GIBBEHGaming
@GIBBEHGaming 4 роки тому
David Batty as well as remove from circuit board
@davidbatty6500
@davidbatty6500 4 роки тому
brandonsg123 I tried doing that when I was doing this for my masters, you can remover the circuitry from the case and disconnect a lot of the components but I tried removing the camera and it just died, I would recommend leaving it on the board majority of the board can be unscrewed and disconnects just a single board with ir transmitter and receiver. Remember also they need to be perfectly separate doe it won’t work. Again speaking form experience.
@GIBBEHGaming
@GIBBEHGaming 4 роки тому
David Batty gotcha, thanks for the info
@neiltsakatsa
@neiltsakatsa 6 років тому
Which model of the KINECT is this ??
@RoboticsWeekends
@RoboticsWeekends 6 років тому
Neil Tsakatsa It's Kinect 360
@neiltsakatsa
@neiltsakatsa 6 років тому
Look under the Kinect stager/ where it sits, there is a model number !
@RoboticsWeekends
@RoboticsWeekends 6 років тому
Neil Tsakatsa this concrete 1473. But it also works with 1414
@neiltsakatsa
@neiltsakatsa 6 років тому
Thank You Very Much :-) Happy Computing !
@ajose1070
@ajose1070 6 років тому
does it work same way with kienct 2.0
@RoboticsWeekends
@RoboticsWeekends 6 років тому
Hi. Unfortunately Kinect v2 won't work on Raspberry Pi, because it needs USB 3.0 port. But even if you have some platform with USB 3.0 ( for example Jetson boards) you should install another Kinect driver - libfreenect supports only Kinect v1
@franciscomartiarena
@franciscomartiarena 4 роки тому
Whats the name of the kinect adapter
@RoboticsWeekends
@RoboticsWeekends 3 роки тому
It's noname from china
@Thatguyyyouknow
@Thatguyyyouknow 2 роки тому
@@RoboticsWeekendscould you provide a link please?
@varunkumartp4409
@varunkumartp4409 2 роки тому
Hi, I'm using a raspberry pi 4 and kinect 360. But the kinect is not detected by pi. It's not listed in lsusb. OS ubuntu server 20.04
@RoboticsWeekends
@RoboticsWeekends 2 роки тому
Please check that Kinect and additional power supply is working. For example on another PC. I had a similar setup without any issues.
@varunkumartp4409
@varunkumartp4409 2 роки тому
@@RoboticsWeekends the kinect work on my laptop. I have given 12v power to the kinect power jack and used the official power adaptor for raspberry pi
@lauro199471
@lauro199471 6 років тому
Why doesnt it work for close range? I put my hand 12 inches away from the IR camera and doesnt show in RVIZ
@RoboticsWeekends
@RoboticsWeekends 6 років тому
Kinect has minimum range 0.5 - 0.8 m , and max 3 - 4 m, depending on version. So you'll see nothing on smaller distances
@forqed
@forqed 6 років тому
I have error with rviz in Fixed Frame: "No tf data. Actual error: Fixed Frame [camera_link] does not exist". Could you help me?
@RoboticsWeekends
@RoboticsWeekends 6 років тому
Hi. Please start with checking your freenect node. Is it works without errors and publishes any data?
@forqed
@forqed 6 років тому
Yes. I check kinect without ethernet connection (only raspberry) and all works. Its looks like connection problem between master and slave but i can ping both.
@RoboticsWeekends
@RoboticsWeekends 6 років тому
In this case I recommend to check environment variables ROS_MASTER_URI and ROS_IP both on master and slave. For details you could refer to my previous video How to setup ROS on RPI
@divyamgarg9078
@divyamgarg9078 5 років тому
you're using ros on ubuntu machine or raspian
@RoboticsWeekends
@RoboticsWeekends 5 років тому
It's ROS on Ubuntu which is installed on Raspberry Pi. There is a separate video on my channel how to install it
@divyamgarg9078
@divyamgarg9078 5 років тому
Robotics Weekends oh thanks for responding could u plz post the link of that video
@RoboticsWeekends
@RoboticsWeekends 5 років тому
@@divyamgarg9078 Sure. Here its - ukposts.info/have/v-deo/jnamfH1kf6Vlp58.html
@divyamgarg9078
@divyamgarg9078 5 років тому
@@RoboticsWeekends Thankyou again
@divyamgarg9078
@divyamgarg9078 5 років тому
@@RoboticsWeekends the work that i have already done on ubuntu using ros... can i transfer that as it is !! sorry for asking such stupid question but it will be a great help if u can just respond one last time and thanx in advance
@aurelianobuendia24
@aurelianobuendia24 6 років тому
I get "Unable to locate package ros-kinectic-freenect-launch"
@RoboticsWeekends
@RoboticsWeekends 6 років тому
+Julian Puppo Hello, that's because you have a typo in package name: instead of kineCtic should be kinetic. "Kinetic" is a ROS version codename.
@aurelianobuendia24
@aurelianobuendia24 6 років тому
I´ve corrected it to : "sudo apt install ros-kinetic-freenect-launch" . Still not working.
@RoboticsWeekends
@RoboticsWeekends 6 років тому
+Julian Puppo It looks like you didn't add apt repository for ROS. By the way, did you install ROS itself before? If not, please refer to my "How to install ROS" video.
@RoboticsLive
@RoboticsLive 6 років тому
i also got the same error with rasbian jessie, then i tried with ubuntu mate. It worked..
@jamiecoates9891
@jamiecoates9891 5 років тому
@@RoboticsWeekends maybe you should produce proper step by step instructions not point to another video because you forgot to include...
@kikoremacha5722
@kikoremacha5722 3 роки тому
Usas un PC y una raspberry? Para que? Conecta directamente al PC y te quitas de lios.
@lauro199471
@lauro199471 6 років тому
I keep getting No Device Connected ... waiting for device to be connected
@RoboticsWeekends
@RoboticsWeekends 6 років тому
Do you see your Kinect in list after lsusb command?
@lauro199471
@lauro199471 6 років тому
Yes
@lauro199471
@lauro199471 6 років тому
So i got it working Thanks to Imesh Sachinda. sudo chmod 777 -R /dev/bus/usb
@RoboticsWeekends
@RoboticsWeekends 6 років тому
Yes, this is the second thing you'll have to do;) Glad that you've already figured out that)
@muhammadshazaib9601
@muhammadshazaib9601 3 роки тому
When I connect Kinect it says no device connected.
@leidyo9193
@leidyo9193 6 років тому
Hi, im new in this kind of setting up Rviz, i did all in the tutorial but at the end it was a Warning in Fixed Frame that says: "No tf data. Actual error: Fixed Frame [camera_link] does not exist" What can i do to solve this ?
@RoboticsWeekends
@RoboticsWeekends 6 років тому
Hi. The camera_link tf is provided by Kinect node. I recommend you to check if Kinect node is up and running without errors
@tourdumonde77
@tourdumonde77 6 років тому
Hi, why don't you connect the kinect directly to the PC via USB (without RPI)? Or, why do you need a PC with ROS as master and do not install Linux with ROS distro directly on RPI to avoid the use of PC ? Thx
@RoboticsWeekends
@RoboticsWeekends 6 років тому
+tourdumonde77 Hi, TL;DR For this video PC is used as data viewer, and there is no any problem to launch roscore and Kinect node entire on RPI. I created these "How to" series based on questions frequently asked to me. That's why I've chosen RPi as proxy. So there is no any problem to connect Kinect directly to PC, if you want to make PC as a part of your mobile robot;) Yes, using PC as master confused some people. I did so, because I'm using such distributed model on my robot - main hub, based on x86 computer board with roscore, plus ARM based boards attached as slaves with different sensors, tasks and purposes. For example in previous "smart camera" video RPi detect faces, controls gimbal, measure distance, etc. And to master PC can be sent only TF messages for object following planning.
@tourdumonde77
@tourdumonde77 6 років тому
@robotics weekends Thank you very much for you exhaustive answer, I really appreciated it ! Keep up the good work
@javiervideos5952
@javiervideos5952 6 років тому
@RoboticsWeekends Sorry, how do you install Roscore on the PC master?
@RoboticsWeekends
@RoboticsWeekends 6 років тому
+Javier Videos roscore is a part of ROS, which can be installed on master PC in the same way as for Raspberry Pi
@javiervideos5952
@javiervideos5952 6 років тому
@Robotics Weekends Thanks for answering, one last doubt! Do you connect with SSH? or what function does the network wire have?
@Tea-Spin
@Tea-Spin 6 років тому
Can we use rpi as master?
@RoboticsWeekends
@RoboticsWeekends 6 років тому
+Ridwan Afwan Karim Fauzi yes, just change ROS_MASTER_URI environment variable
@arjunsharma3248
@arjunsharma3248 6 років тому
Hi Sir, my team and I are working on a project which requires the use of Kinect for mapping. But we have not got much progress. Could you help us?
@RoboticsWeekends
@RoboticsWeekends 6 років тому
Hi. You can use described here system as a source for laserscan data, which is needed by gmapping node. Please check for gmapping wiki on ROS page for more information
@Dylan-cs2vv
@Dylan-cs2vv 2 роки тому
unable to locate package ros-kinetic-freenect-launch
@RoboticsWeekends
@RoboticsWeekends 2 роки тому
You also can build it from sources. How to do that is described in the video about Kinect and NVIDIA Jetson Nano on my channel.
@boscomadassery9667
@boscomadassery9667 3 роки тому
Won't let me download the first package
@RoboticsWeekends
@RoboticsWeekends 3 роки тому
Do you have already installed ROS as it is described here wiki.ros.org/Installation/Ubuntu ? To install ros-melodic packages you should have set up ros repository. Please refer the link for more details.
@boscomadassery9667
@boscomadassery9667 3 роки тому
@@RoboticsWeekends thanks I'll check it out
@RagingMonkee
@RagingMonkee 6 років тому
Anybody else having this problem? "No device connected..." repeating. I don't have a /dev/bus/ directory I only have /dev/tty/ and chmod did NOT work. Lsusb shows all Kinect devices look correct too. Seems to get stuck on last step... ukposts.info/have/v-deo/cKalZ7CFsJeQyas.html
@charleyboy74
@charleyboy74 4 роки тому
Gutted. Unable to locate package ros-kinetic-freenect-launch
@RoboticsWeekends
@RoboticsWeekends 4 роки тому
Freenect package can be installed from sources.
How to connect Neato XV-11 Lidar to Raspberry Pi 2 or 3 with ROS
7:38
Robotics Weekends
Переглядів 27 тис.
Easy SLAM with ROS using slam_toolbox
25:47
Articulated Robotics
Переглядів 104 тис.
0% Respect Moments 😥
00:27
LE FOOT EN VIDÉO
Переглядів 40 млн
3D Scanning with XBox One Kinect Sensor
11:39
Crosslink
Переглядів 150 тис.
13 Stunning Raspberry Pi Projects for 2024!!!
10:23
ToP Projects Compilation
Переглядів 157 тис.
12.2: The Depth Image - Kinect and Processing Tutorial
14:58
The Coding Train
Переглядів 142 тис.
Android Auto Raspberry Pi 3 Crankshaft OpenAuto
7:00
ETA PRIME
Переглядів 951 тис.
2D Mapping using Google Cartographer and RPLidar with Raspberry Pi 3B+
13:36
Robotics Weekends
Переглядів 44 тис.
Raspberry Pi 4 - How to Setup & Get Started (Best projects for beginner)
11:45
Interactive Particles - TouchDesigner + Kinect Tutorial 1
26:02
bileam tschepe (elekktronaut)
Переглядів 141 тис.
RPLidar and Hector SLAM for Beginners | ROS Tutorial #8
9:41
Tiziano Fiorenzani
Переглядів 147 тис.
How to get your robot to see in 3D! (Depth Cameras in ROS)
23:21
Articulated Robotics
Переглядів 54 тис.
НЕ ПОКУПАЙТЕ НОВЫЙ СМАРТФОН, ПОКА НЕ ВЫШЕЛ ЭТОТ [2024]
13:25
Thebox - о технике и гаджетах
Переглядів 82 тис.
Лучший Смартфон До 149 Баксов!!!??? itel s24
20:25
РасПаковка ДваПаковка
Переглядів 47 тис.
🤯Самая КРУТАЯ Функция #shorts
0:58
YOLODROID
Переглядів 2,9 млн
Игровой ноутбук за 100тр в МВИДЕО
0:58
KOLBIN REVIEW
Переглядів 398 тис.