Archive for category Linux

Installing Bumblebee for using gazebo and rviz on asus 1215n

I installed ubuntu 11.04 (natty) as a fast solution for the problems I found with 11.10 and in this version I found problems with the drivers of the graphics card to be able to run gazebo and rviz. I found the next error when trying to run gazebo:

Xlib: extension “GLX” missing on display “:0.0″.
Insufficient GL support

To solve the problem it’s enough to install Bumblebee following the instructions of: https://launchpad.net/~bumblebee/+archive/stable

sudo apt-get purge nvidia-current
sudo add-apt-repository ppa:ubuntu-x-swat/x-updates
sudo add-apt-repository ppa:bumblebee/stable
sudo apt-get update
sudo apt-get install bumblebee

sudo usermod -a -G bumblebee $USER

Reboot and to try if it works they recommend running for 30s: glxspheres
Then compare it with optirun running: optirun glxspheres

In my case I can see how I go from 10fps to 31fps!

When running gazebo without optirun I found the following error:
XRequest.137: BadDrawable (invalid Pixmap or Window parameter) 0×4400002

But using optirun this error does not show up. And we win some fps.

Tags: , , , ,

Installing ROS electric and ROS diamondback on Ubuntu Oneiric (11.10)

The thing is that I installeds first on Ubuntu 11.10 ROS electric using their instructions, then I needed to install ROS diamondback.

I tried to use their instructions to install it from the repositories and I found this problem:

sudo apt-get install ros-diamondback-desktop-full
Reading package lists… Done
Building dependency tree
Reading state information… Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
ros-diamondback-desktop-full : Depends: ros-diamondback-ros-tutorials (= 0.2.4-s1312445230~lucid) but it is not going to be installed
Depends: ros-diamondback-geometry-tutorials (= 0.1.3-s1312445373~lucid) but it is not going to be installed
Depends: ros-diamondback-slam-gmapping (= 1.2.3-s1312435634~lucid) but it is not going to be installed
Depends: ros-diamondback-ros (= 1.4.9-s1312417708~lucid) but it is not going to be installed
Depends: ros-diamondback-visualization (= 1.4.1-s1312432000~lucid) but it is not going to be installed
Depends: ros-diamondback-vision-opencv (= 1.4.3-s1312425872~lucid) but it is not going to be installed
Depends: ros-diamondback-perception-pcl (= 0.10.0-s1312427042~lucid) but it is not going to be installed
Depends: ros-diamondback-rx (= 1.4.2-s1312430459~lucid) but it is not going to be installed
Depends: ros-diamondback-image-pipeline (= 1.4.2-s1312437407~lucid) but it is not going to be installed
Depends: ros-diamondback-simulator-gazebo (= 1.2.8-s1312440157~lucid) but it is not going to be installed
Depends: ros-diamondback-diagnostics-monitors (= 1.4.0-s1312439740~lucid) but it is not going to be installed
Depends: ros-diamondback-simulator-stage (= 1.2.5-s1312437801~lucid) but it is not going to be installed
Depends: ros-diamondback-image-common (= 1.4.1-s1312425748~lucid) but it is not going to be installed
Depends: ros-diamondback-common-tutorials (= 0.1.2-s1312463072~lucid) but it is not going to be installed
Depends: ros-diamondback-ros-comm (= 1.4.7-s1312424712~lucid) but it is not going to be installed
Depends: ros-diamondback-visualization-common (= 1.4.2-s1312430681~lucid) but it is not going to be installed
Depends: ros-diamondback-physics-ode (= 1.4.1-s1312430103~lucid) but it is not going to be installed
Depends: ros-diamondback-driver-common (= 1.2.3-s1312425659~lucid) but it is not going to be installed
Depends: ros-diamondback-executive-smach (= 1.0.2-s1312435548~lucid) but it is not going to be installed
Depends: ros-diamondback-common-msgs (= 1.4.0-s1312425065~lucid) but it is not going to be installed
Depends: ros-diamondback-image-transport-plugins (= 1.4.1-s1312426755~lucid) but it is not going to be installed
Depends: ros-diamondback-robot-model (= 1.4.0-s1312427974~lucid) but it is not going to be installed
Depends: ros-diamondback-visualization-tutorials (= 0.2.2-s1312464635~lucid) but it is not going to be installed
Depends: ros-diamondback-geometry (= 1.4.2-s1312425346~lucid) but it is not going to be installed
Depends: ros-diamondback-documentation (= 1.4.1-s1312464754~lucid) but it is not going to be installed
Depends: ros-diamondback-executive-smach-visualization (= 1.0.1-s1312459854~lucid) but it is not going to be installed
Depends: ros-diamondback-laser-pipeline (= 1.2.0-s1312429600~lucid) but it is not going to be installed
Depends: ros-diamondback-common (= 1.4.3-s1312425161~lucid) but it is not going to be installed
Depends: ros-diamondback-diagnostics (= 1.4.0-s1312425553~lucid) but it is not going to be installed
Depends: ros-diamondback-navigation (= 1.4.1-s1312429823~lucid) but it is not going to be installed”

I started trying to correct it and I followed the next (failed) steps:
So I tried to install it from source with this instructions. In a step (in the package geometry) I got asked for an user and password, I just hit Enter and everything went fine.

Changed the path where to install as by default is ~/ros but I found it nicer to be in /opt.

This lasted… one hour. And I got an error in the end, so I wasn’t happy.

So I found this link: http://answers.ros.org/question/2505/installing-ros-diamondback-on-ubuntu-1110-oneiric
Where a good soul explains how to install it. I find it ugly, but works!

Oh, and finally I need to be sure that I am using the correct version of ROS putting in my .bashrc the line:

source /opt/ros/diamondback/setup.bash

(or the one that is correct in that moment, electric, or diamondback).

Tags: , ,

Installing OSCeleton Sensebloom in Windows 7 64 bits

To install OSCeleton you must follow the steps that you can find at SensorKinect but they don’t mention a couple of details:

-You must install the 32 bit version of OpenNI and NITE because SensorKinect does not have a 64bit version and it does not recognize the 64 bits of them installed.

-You must go to environment variables (Control Panel\System and security\System, left, advanced system settings, down you find EnvironmentVariables) and modify the register OPEN_NI_BIN so it contains: C:\Program Files (x86)\OpenNI\Bin (for me), the difference is that it said “bin” and not “Bin” in my default installation so it does not find the binaries. If you don’t make this change when you try to execute some demo you will get: “OpenNI library can’t find any module!”.

Found the solution in this thread,

Tags: , , , , ,

Update VLC in Ubuntu 10.04 to the last version

Today I compressed a video with x264 codec and in a MP4 container with Avidemux and when I tried to play it with VLC it had errors showing it. This is because the official repositories of ubuntu of VLC have the version 1.0.6 and the most updated version right now while I’m writting this is the 1.1.7.
With the new version this error does not happen.
To update your VLC you only need to follow the instructions that you can find here and I’m reproducing them here:


sudo add-apt-repository ppa:lucid-bleed/ppa
sudo apt-get update
sudo apt-get install vlc vlc-plugin-pulse mozilla-plugin-vlc

Tags: , ,

Kinect with OpenCV first contact!

After fighting all day with it I’ve got the basic stuff with Kinect, getting the RGB image and the Depth image and show them in real time.

For doing it I wanted to use OpenCV and the libfreenect driver. I’ve been able to do it thanks to the example of OpenKinect.org thats posted on here.

My code looks like this:

Tags: , ,

Skip password of default keyring in Ubuntu 10.04

Today just after getting up my Ubuntu asked me for “Default password for default keyring to unlock”… and that irritated me as I wanted to connect to my home network as everyday. So, to skip this window the next time you start a session you can follow the next steps:

1. Right click on the network icon > Click Edit the connection...
2. Go to the Tab of your connection (Wireless for me), click the network you trust and click Edit...
3. Check the "Make avaiable for all users" checkbox (and watch that the "Connect automagically checkbox is checked too!).
4. Apply.

I hope this helps someone :)

Tags: , , , , , ,

Recover Grub2 (Ubuntu 10.04 and forward)

As we can see in guia-ubuntu to recover our Grub2 that we’ve lost while installing another SO we need to load any live cd and follow the next steps:

Lets see the structure of our disk:

sudo fdisk -l

Mount the partition where we have our Ubuntu installed:

sudo mount /dev/sda1 /mnt

Mount the rest of the virtual devices:

sudo mount --bind /dev /mnt/dev
sudo mount --bind /proc /mnt/proc

We get access as root to our system (from now on the console will be in our system):

sudo chroot /mnt

And we execute a grub reinstall:

grub-install --recheck /dev/sda

And we can boot our system from the grub2 we had previously. To update the list of SOs we can execute (AFTER REBOOTING INTO OUR SYSTEM):

sudo update-grub2

And thats all folks :)

Tags: , , , , ,

Recover Touchpad Ubuntu

Today I upgraded the ubuntu of my netbook and I found out that when I came back to the OS my Touchpad didnt work anymore. After trying to fix it with the man of xorg.conf and failing googling i found the solution:

You need to login as root (sudo does not work) and execute the following command.

echo options psmouse proto=exps > /etc/modprobe.d/psmouse.modprobe

And after that reboot.

PS: If you don’t have an external mouse to plug in, hitting control+alt+F2 you can find a console.

Via: danilogurovich

Tags: , , , , , ,