So you picked up your very own Stellaris Launchpad, a TI ARM dev board which can be in your hands for just five bones. They do distribute several free IDEs which are not size-limited but perhaps you’re more of a text editor and command line sort of person. Well you’re in luck. There’s now a guide to show you how to code for and program the Stellaris Launchpad from a Linux box with using one of the IDEs.
There are two main things that are needed to accomplish this. The first is a cross-compiling toolchain for the ARM architecture; something that has been readily available for quite some time. The second is a way to talk to the in-built Stellaris programmer from a Linux machine. The hardware uses the ICDI protocol, and as we reported last week the lm4tools project can be used for this purpose. The guide also covers building the StellarisWare package. It’s not a requirement, but it makes using the peripherals much easier and provides names for the I/O pins, etc.
Our favorite for debugging microcontroller projects is OpenOCD. From this thread post it looks like there is now ICDI support in the development branch of the software if you don’t mind compiling from source.
42 thoughts on “Guide To Developing With The Stellaris Launchpad On A Linux Box”
Introductory price was introductory. Unless the conversion rate is $2.60 to one bone, this is misleading– current price $13.
I bought three from Avnet express Saturday for $14.97 plus $8 shipping… As of 8pm pst there are still 399 available at that price. Mine are scheduled to arrive Thursday :)
(14.97 = 4.99*3, sorry should have been clearer). They are still available for 5 “bones”
I don’t know if your comment is bullshit or you live on a different internet…but the last i’ve seen these for $5 was some time ago. Moreover, i ordered mine a day or two after it was announced, and it’s scheduled to arrive nov 8.
I am not joking, mine are arriving today. Check out Avnet Express and search for stellaris launchpad, here is a link to the product page: http://avnetexpress.avnet.com/store/em/EMController?langId=-1&storeId=500201&catalogId=500201&term=Stellaris%2Blaunchpad&x=0&y=0&searchType=&advAction=&N=0&Ne=100000&action=products
They did go up a little since I posted, they are $5.60 when I checked this morning and you do need to pay $8 shipping right now (which is why i bought 3, hate to pay more for shipping than product) but it is still an incredible deal! Only 268 left in stock and it is three business days to ship.
Perfect timing! My two boards turned up yesterday – in a Fed-Ex two-day delivery box from Fort Worth, TX to New Zealand.
Just got mine in the mail today! Not sure what I’m going to use it for…but can’t beat the price!
im still waiting for mine. their fedex service is amazing.
Again, ¡perfect timing! ¡I also received my two boards yesterday!
It’s too bad TI canceled my preorder so I have to wait even longer (and had to pay full price).
Hey I think that happened to me too. Do you know the details to wtf is going on? I’m getting pretty pissed hearing everybody got their board when I ordered mine the day of it was announced.
I’m about to say FK YOU ti and start the planned project with another god damn platform.
Don’t feel too bad.
I’m still waiting on the original launchpad to ship. Ya… like two YEARS ago.
They wont reply to any mails about it and the order number has been recycled since. What?
I did however get the new one today.
If you order from TI and anything funky happens with your order, expect it to be lost and get on them asap via phone.
Anybody thinking about to release code based on the CMSIS style device header should think twice. . At least the file you get via http://www.ti.com/tool/cmsis_dsp_headers contain nasty disclaimers The disclaimers only talk about ” object or executable versions only” and tells “You shall maintain the source code versions of the Licensed Materials”.
So again, be warned!
The “driverlib” code (headers and C functions) seem to be under the BSD license. But the sample programs as well as startup code and linker scripts explicitly prevent mixing with “viral” licenses :( Any idea how this problem can be solved? (the startup/linker scripts are trivial programs – maybe we can just do a rewrite?)
Someone else already has:
Sorry, I dropped some words.Th last quote should be: “You shall maintain the source code versions of the Licensed Materials under password control protection”
Glad all this stuff is coming available, will make it easier once I get it… They’re not shipping mine for another 2 weeks. :(
I hear you man. All of these MFers from crazy places over the world getting theirs with 2day shipping, yet I’m in the same shipping zone of TI’s headquarters, ordered the day it was announced, and have to wait till nov 8.
I’ll fcking remember this TI the next time I select components for a project at work…
Mine still didn’t even ship.
Just checked order status on mine. Mine says payment unprocessed yet I was billed for it. Customer service will be getting a VERY angry email tommorow
Mine won’t ship until december, and i placed the order a month ago today. Oh well, get what i pay for, or something like that.
This is awesome, I was sticking to other development boards but now that there is a guide to doing this cli, I can finally test out the stellaris!
I have just started to read the Stellaris documentation (http://processors.wiki.ti.com/index.php/Reading_Stellaris_Documentation)
I have just discovered that I have to make a huge investment if I am going to get the best out of these $4.99 boards.
The datasheet for the chip is 1168 pages, the library guide another 518 pages, another 330 pages of ROM functions – there is 30 ROM functions just for using the GPIO pins!
Compare that with the Raspberry Pi – it may not be anything like a decent micro-controller, but the only documentation I needed to get started was how to ‘dd’ the boot image onto a SD card…
So it is tough call time – do I even bother to open the box at all, or just put them in the bottom draw?
You don’t have to read the +1K page of a UC datasheet unless you have time, or really want to.
You need to use GPIO? check the chapter on gpio, look for a good example then modifi it for what you need. Or google it.
Same thing with every other peripheral.
That’s not the fairest comparison. A linux computer with a standard operating system to a relatively new microcontroller?
Yeah, I guess you are right – The Pi is 4x the usual price, 10x the clock, 8,000x the storage (SD card), 8,000x the RAM, has Ethernet & Video, no need for a Laptop/PC to code on… but only 1% the I/O :-)
But if somebody were to code some firmware for the Stellaris to turn it into an USB I/O expander for the Pi (and other Linux boards), maybe with some PLC-like programmable functionality, that would be a pretty sweet.
pi has uart, this has uart. Done.
Thing is, it’s not actually all that complicated to get started — you just need to have a good walkthrough. I was up and running on the last Stellaris board I got in an hour or two at most.
Maybe someone should do some step-by-step walkthroughs!
TI already made great walk through videos: http://processors.wiki.ti.com/index.php/Getting_Started_with_the_Stellaris_EK-LM4F120XL_LaunchPad_Workshop?DCMP=stellaris-launchpad&HQS=stellaris-launchpadtraining
If you’re just looking to get started, the only document I would read is the Stellaris Peripheral Driver Library document (spmu019u). It’s perfect for someone who is already familiar with microcontrollers and just wants to get their feet wet. It explains all the library functions along with lots of examples.
Copying an existing example and then using this document should allow you do most of what you’ll want to use this micro for.
It’s not worth it send it to me.
Can the Raspberry Pi toolchain be used with the Stellaris Launchpad along with the lm4tools project?
I don’t think so – the stellaris launchpad needs a “bare metal” toolchain, ie, a toolchain which generates code running on a machine without any operating system coming in the picture.
FYI, this guide for lm4tools is working also on OSX 10.8, with just few minors changes. Next on is gdb on OSX…. :-D
Glad to know it is working on OSX.
I did try out gdb on Linux … but it was showing some problems.
Help me out! I want to do this!
I would love to know what you had to change to get it to work!
OK, here is small post with all commands required to build and install lm4tools and arm gcc toolchain.
note: this is mostly c/p from sources mentioned in post…
Very good post AmosSam! Btw, I use homebrew instead of macports to manage my packages and it also works well. I develop lm4flash on a Mac, so it has been working on the Mac from day one!
Newark actually has these for six dollars or so apiece, but isn’t expecting any stock until mid November. I’ve got two on order from TI that aren’t scheduled to ship until 12/17, so I’ll pick up one from Newark and have a few units to play with.
I’m really excited to read all these updates because my preferred dev environment is my Mac, however I’m going to try to get everything working in combination with Eclipse CDT. Curious to hear whether anyone has given this a try yet!
first, sorry for reporting your comment martytoof, wrong link clicked! :-(
I’m also working in Eclipse, so that is my final goal with this, but I’ll first try to setup gdb and then to setup Eclipse… I’ll post to my blog any attempts made…
Will it be possible to eventually have debugging working in Eclipse with CDT+OpenOCD similar to how the CCS Studio Eclipse plugin works?
Please be kind and respectful to help make the comments section excellent. (Comment Policy)