Compiling code for Stellaris Launchpad with TivaWare
So, half a year has passed by since I received Stellaris Launchpad kits from Texas Instruments. I just could not resist the temptation to get two of them for $5 each and I might just have found an application for them. Okay, let's write some code.
Wait, I have no toolchain.
Since I do not use Windows anymore, I had the joys of piecing the toolchain together from many pieces.
Getting the toolchain and lm4flash
(used to flash the binary to controller) has already been well documented (see, 1, 2), I'm not covering it here.
The problem I encountered was that TI have deprecated StellarisWare, which contains C libraries to interact with controller's peripherals. Texas Instruments website is riddled with broken links to old StellarisWare, so it was not obvious that they have replaced it with something else.
StellarisWare has been replaced with TivaWare. TI provides a nice document outlining migration procedure here.
For basic operation of Stellaris Launchpad controller, only Peripheral driver library is required.
Download, unzip it, make
it.
Ok, we got the toolchain ready. Now we need something to make. Mauro has provided a template with nifty Makefile which supposedly does what we need.
Unfortunately, it does not work with TivaWare driver library, so I forked it and made it work.
Just be sure to change STELLARISWARE_PATH
in the Makefile to point to TivaWare driver library path.
Comments