Friday, October 11, 2013

GNU for ARM bare metal toolchain installation on Ubuntu 12.04 LTS

Hi all.
Here I'm writing about installation of GNU arm-eabi toolchain on Ubuntu 12.04.

1. Dependency install (x64 system, do this with care)

 First, you need to install dependencies below. If you are using 64-bit Ubuntu, you should install ia32-libs for using GNU-arm binary for 32-bit compatibility. Also, several utilities for the future use, install following packages.

sudo apt-get install python-serial python-argparse openocd \
    flex bison libncurses5-dev autoconf texinfo build-essential \
    libftdi-dev libtool zlib1g-dev genromfs ia32-libs git-core wget

2. Toolchain download 

I'm assuming that you will install toolchain in your home directory.
I prefer to download built binaries because there is no specific reason for
compiling compiler on the machine (also takes long time!).

You can select whatever version from https://launchpad.net/gcc-arm-embedded/
But this is know-to-work version in my case.

I'm using "axel" for faster download. It makes several download task simultaneously, utilizing multi session download.

sudo apt-get axel
cd ~
axel https://launchpad.net/gcc-arm-embedded/4.6/4.6-2012-q2-update/+download/gcc-arm-none-eabi-4_6-2012q2-20120614.tar.bz2
tar -vjxf gcc-arm-none-eabi-4_6-2012q2-20120614.tar.bz2
exportline="export PATH=$HOME/gcc-arm-none-eabi-4_6-2012q2/bin:\$PATH"
if grep -Fxq "$exportline" ~/.bashrc; then echo nothing to do ; else echo $exportline >> ~/.bashrc; fi
source ~/.bashrc

3.Installation check
$ arm-none-eabi-gcc --version

You should see following message.

arm-none-eabi-gcc (GNU Tools for ARM Embedded Processors) 4.6.2 20120613 (release) [ARM/embedded-4_6-branch revision 188521]
Copyright (C) 2011 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Friday, October 4, 2013

About Speeded Up Robust Features (SURF)

I recently started to implementing SURF for my visual SLAM project.
During exploration of algorithm implementation, I found many projects that well implements the original idea by Herbert Bay et al.
Whatever modern feature descriptor you are using, most scale-invariant feature descriptors output sequence of floating numbers that encodes given image patch.
Along with the vector of descriptors, scale, detected octave are also important variables for the feature.

In this article, I'll explain what is the *scale*.

The scale is a scalar variable describes the width of Gaussian kernel which roughly gives an idea of distance of feature.

In case the OpenCV, the scale can be obtained as follows.
The KeyPoint structure, let say kpt, has a member variable 'size' which the number represents the size of the patch. To obtain the filter size, use std::sqrt(kpt.size).

In the original paper, the smallest filter size is 9x9. So the scale will be

   scale = 1.2 * ( filter_size / 9 )

[Links]

  1. http://experienceopencv.blogspot.kr/2011/01/surf-detector.html
  2. http://www.computerrobotvision.org/2010/tutorial_day/tam_surf_rev3.pdf

Thursday, May 30, 2013

[git] Move git repository


$ git remote add <newreponame> <new_repository_URL>
$ git push <newreponame> master
$ git remote rm origin
$ vi .git/config (rename newreponame to origin).

That's all.

References
[1] http://stackoverflow.com/questions/1484648/how-to-migrate-git-repository-from-one-server-to-a-new-one

Tuesday, May 28, 2013

[git] Show all changed files between two commits/branches

It is useful to see only the name of the files changed.
But $ git diff, will give you a line-by-line result of changes.

Here is how.
$ git diff --name-only SHA1 SHA2
or
$ git diff --name-only <branch_name>

But this will be better
$ git diff --name-status

Good luck!

References
[1] http://stackoverflow.com/questions/1552340/git-show-all-changed-files-between-two-commits

Saturday, May 25, 2013

Brushless gimbal

This blog post describes bunch of information on brushless gimbal.
It will be updated when I found something.

Gimbal frame design
3D Printable : http://www.rcgroups.com/forums/showthread.php?t=1864420

News
Maxon motor : http://www.maxonmotor.com.au/maxon/view/application/PHOTOHIGHER-AB

Company
Photohigher : http://www.photohigher.co.nz/products/

Brushless motor operation principals

Brushless motor (synchronous motor) is interesting motor familiy.
But, the operation principal is bit hard to understand.
So I here describe some useful animation of those kind of motors for YOU.

Brushless Motor : This motor is designed to rotate permanent maget by commuting two leads.
http://educypedia.karadimov.info/library/4-pole-bldc-motor031102.swf


Synchronous Motor : This motor is designed to rotate permanent magnet by commuting
leads with sine wave.
http://educypedia.karadimov.info/library/Synchronous_Motor_Principle.swf







Lenz Law


References