ACE Home Page
 
 



Gumstix

Greg Elliott is currently responsible for this page. Questions regarding it can be directed to

gelliott THE AT SIGN gmail THEN A DOT com.

How to get your gumstix, and get it running

Here’s the general idea of how this is going to go: Buy your gumstix, buy cables and interfaces to connect to it, build a new filesystem (called a buildroot) that has all the stuff you’re going to need (audio libraries, python, sql, bluetooth, etc.), put this new buildroot onto the gumstix (over serial or using mmc memory cards), boot it up and check it out.

Step 1: Buy Hardware

Gumstix Website

Step 2: Power it on, Log in, leave

Step 3: Make a new filesystem for the Gumstix

Step 4: Put the new filesystem onto the Gumstix

Step 5: Play around

Software for PIC programming

first, you need a compiler. why? so you write your code in C, or assembly, or python or whatever. then you have to compile that code, but you can’t just use the compiler you happen to have lying around. oh no, you need a compiler that can make code just for the pic chip you want to use. so, pick the language you wanna write in and download the appropriate complier.

  • PYTHON (ALPHA) – Pyastra – takes Python code and compiles it to assembly!! then you can just hand it off to GPUtils (below) to compile it into code for the Pic. TOO COOL!
  • ASSEMBLY – GPUtils – open source pic compiler ASSEMBLY ONLY (linux, osx, win, etc)
  • C – BoostC Compiler – C compiler (Linux/Win)”:

    There’s a nice pic simulator (optional) that allows you to test your code in a simulated environment. Lin/Win only. =(

  • GPSim – open source pic simulator

    So now you have your code, it’s compiled and ready to go. How do you get it onto the PIC? Enter: PicP. It sends your nicely compiled code to the PIC and flashes it onto the chip.

  • PicP – open source command-line interface for PicStartPlus Pic Programmer

    Python

  • Python itself – The recent buildroots include a stub for python. Beware, it takes up 7megs. The gumstix flash chip is* about 16megs, so if you’re not planning to use the onboard MMC (or don’t have it) or a CF card, remember that python will eat up some precious space.

    So, follow the instructions above to get to the buildroot menu, arrow down to Python, check it, exit and save then ‘make’ the buildroot.

  • Python modules – tricky. many python modules are .c files that get compiled into a .so (shared object, kinda like a .dll in windows). you then put this .so into the python library directory (for gumstix, this is /lib/python2.yourversionhere/site-packages). to compile the modules for the gumstix, you could compile each c file by hand, and then link them together into the .so file. this is a little dirty depending on the module (pysqlite is a good example).

    here’s my trick: the python files by default use the /usr/bin/gcc compiler. i wasn’t root on the linux system i was using, so i:

    1. reset my path to include the gumstix compiler (arm-linux-gcc, see above if you don’t know what this is) and not include the /usr/bin directory. then i made a link named ‘gcc’ and pointed it to the arm-linux-gcc file. here are the terminal commands to do that (substitute your gumstix dirs and what not)

    > $PATH
    > (your path is shown, copy it)
    > export $PATH=(paste here), then remove the :/usr/bin part
    > ln -s ~/mygumstixpath/staging-dir/bin/arm-linux-gcc ~/bin/gcc

    now just run python setup.py build as you normally would. python will find a gcc in your ~/bin directory, and use that. that file of course poitns to arm-linux-gcc, so you’ll be compiling the module using the gumstix cross-compiler. when it’s done, you’ll have a .so tucked away in the python module’s directory that you’re in, under lib/xxxxxxx86.lib/lib/ or somethign like that.

    copy that to the gumstix, put it in /lib/python2.4.xxxxx/site-packages.

    for certain modules, you might need to also copy over .so’s for the libraries your new module depends on. to check what your new python module depends on, do

    Audio

    Compact Flash

    I/O: How to connect your own boards to the gumstix

    Power

    Programming: How to write your applications and compile them to run on Gumstix

    Example projects using Gumstix

  • GPS Logged

    Definitions and Terms

  • Buildroot – a complete linux filesystem. this means all the /usr, /bin, /lib stuff. all of that. the gumstix buildroot sdk will compress all of it into a jffs2 image which you can send over to your gumstix and flash onto its memory to replace its current operating system/filesystem.

Active Members::
Create or Find Page:
 

Search Wiki:
 
 ·   Categories
 ·   Title List
 ·   Uncategorized Pages
 ·   Random Page
 ·   File Upload
 ·   Uploaded Files
 ·   Recent Changes
 ·   What Links Here