Xtion on RaspberryPi w OpenNi2

1,540 views
Skip to first unread message

HCW

unread,
Jan 23, 2013, 3:23:01 PM1/23/13
to ros-s...@googlegroups.com
Hi Folks.

Just wanted to let you know that i got my Xtion Pro Live running under RaspberryPi.

Steps done:
1) Checkout OpenNi2 repo from github, branch master
2) fixed some compiler errors (i can provide details if anyone is interrested. Will put changes on github soon.)
3) compiled
4) ran examples.

Got CPU Load from SimpleReader of about 16%.

If anyone is interested, please contact me.

Kind regards

Hauke

kevin

unread,
Jan 23, 2013, 6:38:04 PM1/23/13
to ros-s...@googlegroups.com
Sorry for the dumb question, but just for clarification. You were able to get the depth and RGB image from Xtion? If so, what frame rates? 

I have been able to get libfreenect to compile, but couldn't get the kinect to work on RPi. No images (RGB or depth) would get produced and people suggested there were issues with RPi's USB implementation. If this is an alternative, then awesome job!

HCW

unread,
Jan 24, 2013, 2:27:53 AM1/24/13
to ros-s...@googlegroups.com


Am Donnerstag, 24. Januar 2013 00:38:04 UTC+1 schrieb kevin:
Sorry for the dumb question, but just for clarification. You were able to get the depth and RGB image from Xtion? If so, what frame rates? 

I did not yet really measure frame rates. I will do this in the next days. My impression is that there arent that many (if any) frame losses since otherwise CPU load should be higher.

I have tried to run the Viewer apps (NiViewer / SimpleViewer) but they both fail since they need GLX (OpenGL). GLX cant be forwarded via X11-DISPLAY-Variable to another host, and the local XServer on the Pi doesnt have OpenGL.

So I tried SimpleReader / EventReader, and they produce steady outputs with real data (only printing the middle point depht).
 

I have been able to get libfreenect to compile, but couldn't get the kinect to work on RPi. No images (RGB or depth) would get produced and people suggested there were issues with RPi's USB implementation. If this is an alternative, then awesome job!


Please note that i used the RPi Model B 512MB with success, Xtion directly connected to the Pi.
On my 256MB Rpi i get USB error messages.

I suspect this has to do with the USB fuses which were removed in the 512MB version. Maybe you should try a powered hub on a 256MB version.

According to the specs the Xtion has 2.5W which is 500mA at 5V, and the 256MB version is said to be able to supply 140mA.

Seems like the 512MB version can supply the Xtion easily.

Regards

Hauke
 

HCW

unread,
Jan 24, 2013, 3:23:09 PM1/24/13
to ros-s...@googlegroups.com
Now i measured frame rate:

$ time ./EventBasedRead | wc
    1400    2813   28066

real    0m48.712s
user    0m4.190s
sys    0m2.400s

Since EventBasedRead emits one line of text per frame, this means i get nearly 30fps.

Kind regards

Hauke

Kai Franke

unread,
Jan 25, 2013, 1:11:57 PM1/25/13
to ros-s...@googlegroups.com
I installed OpenNi on the RasPi like described here. Are your compiler errors different from that? If yes, I am definitely interested in any details. It would be great if you could add the instructions to the wiki page. Do you necessarily need OpenNi2 or is OpenNi enough? Did you install anything else?

Kai

HCW

unread,
Jan 27, 2013, 4:04:28 PM1/27/13
to ros-s...@googlegroups.com


Am Freitag, 25. Januar 2013 19:11:57 UTC+1 schrieb Kai Franke:
I installed OpenNi on the RasPi like described here. Are your compiler errors different from that? If yes, I am definitely interested in any details. It would be great if you could add the instructions to the wiki page. Do you necessarily need OpenNi2 or is OpenNi enough? Did you install anything else?

Hi Kai.

Actually i found the Link http://mewgen.com/Ge107_files/20120919%20Setting%20up%20Rasberry%20pi%20for%20the%20Xtion%20and%20kinect.htm which comes from http://www.youtube.com/watch?v=jg-RXRpMmNY

I tried OpenNi (1.5.xxx) on Ubuntu and it spotted with an error at me, so i tried 2.0.xxx for Ubuntu then which worked.

So i choosed to use OPenNi2.0 also for RaspberryPi.

I needed to took the compiler flags as described in http://mewgen.com/Ge107_files/20120919%20Setting%20up%20Rasberry%20pi%20for%20the%20Xtion%20and%20kinect.htm but otherwise not mutch patching was needed.
The mayor other thing i did was to comment out the not working (and unused) file UsbLinux-something.cpp and add byte order defines in XnPlatform.h.

(This is from memory. So i need to put up a Github now....)

Kind regards

Hauke

HCW

unread,
Jan 30, 2013, 3:49:58 PM1/30/13
to ros-s...@googlegroups.com

Ok, here is the Github repo of the things i did change:

https://github.com/hcw70/OpenNI2

Kind regards

Hauke

HCW

unread,
Feb 1, 2013, 9:30:22 AM2/1/13
to ros-s...@googlegroups.com


Am Donnerstag, 24. Januar 2013 00:38:04 UTC+1 schrieb kevin:
Sorry for the dumb question, but just for clarification. You were able to get the depth and RGB image from Xtion? If so, what frame rates? 



Dunno if you have seen this http://www.raspberrypi.org/phpBB3/viewtopic.php?p=274686&sid=5b4ef38a32a1a4aa3180552c0cac4c3c#p274686

The Guy seems to have an OpenGL-ES Viewer for the Pi ... 8->

Regards

Hauke
 
Reply all
Reply to author
Forward
0 new messages