Category Archives: Processors

Raspberry Pi Robot #0

I am trying to build my own [amazon &title=Raspberry Pi&text=Raspberry Pi] based robot. Someday, it shall be able to drive autonomously based on data from its [amazon &title=Asus Xtion&text=Asus Xtion] (a smaller version of an Xbox Kinect) and with the help of ROS (Robot Operating System). For today, it is only capable of driving straight forward.

PiRosBot #Zero

Parts:

  • [amazon &title=Asus Xtion&text=Asus Xtion] Pro
  • a [amazon &title=Raspberry Pi&text=Raspberry Pi] Model B Rev.2.0
  • WLAN USB stick
  • two Stepper Motors 28BYJ-48 Datasheet PDF 5V controlled by an ULN2003A Chip
  • an easyAcc Powerbank with 10.000mhA with an MicroUSB Cable supplying 2A of power
  • some metal toy constuction set parts including 3 wheels
  • 8 old female to female jumper wires
  • 2 Y female jumper whires (to share positive and ground of the raspberry with the motors)

With this setup, the raspberry i able to run at least 8 hours by the power of my already a little bit aged powerbank. Driving at an unbelievable slow speed of about 30 seconds per meter (full torque mode of steppers).

For documentation (and for fun, because I never did this before), here a small video of the very first test drive:

Youtube Video

 

Howto: OpenCV 2.4.9 on Raspberry Pi from source

OpenCV is a powerful tool for building computer vision based applications. For one of my projects, I needed it to be compiled on my Raspberry.

Installing it from repositories was not an option because of its too old version.
If this wouldn’t bother you, consider using: sudo apt-get install libopencv-dev

Here is how I installed it on my Rasbian Wheezy from source:

prerequisites:

sudo apt-get -y install build-essential cmake cmake-qt-gui pkg-config libpng12-0 libpng12-dev libpng++-dev libpng3 libpnglite-dev zlib1g-dbg zlib1g zlib1g-dev pngtools libtiff4-dev libtiff4 libtiffxx0c2 libtiff-tools libjpeg8 libjpeg8-dev libjpeg8-dbg libjpeg-progs ffmpeg libavcodec-dev libavcodec53 libavformat53 libavformat-dev libgstreamer0.10-0-dbg libgstreamer0.10-0 libgstreamer0.10-dev libxine1-ffmpeg libxine-dev libxine1-bin libunicap2 libunicap2-dev libdc1394-22-dev libdc1394-22 libdc1394-utils swig libv4l-0 libv4l-dev python-numpy libpython2.6 python-dev python2.6-dev libgtk2.0-dev pkg-config

after that:

downloading the zipfile into a folder located in $HOME

mkdir ~/opencv
cd ~/opencv
wget http://downloads.sourceforge.net/project/opencvlibrary/opencv-unix/2.4.9/opencv-2.4.9.zip 
unzip opencv*.zip
cd opencv*
mkdir build
cd ./build/
cmake -D CMAKE_BUILD_TYPE=RELEASE -D CMAKE_INSTALL_PREFIX=/usr/local -D BUILD_PYTHON_SUPPORT=ON -D BUILD_EXAMPLES=ON
make
sudo make install

Make took about 6-7 hours on my Raspberry Pi, so be sure you have a stable connection or consider using a tool like ‘screen’.

Please also see:

For  openni2_camera it’s not necessary to go further like other posts suggested.