Using the Stellaris Launchpad as a Logic Analyser

Stellaris LaunchpadLike many people I bought a couple of the Stellaris Launchpads when they were on offer at $4.99 each including shipping, and I imagine I am not alone in having stashed them away and done nothing with them. I’ve recently become aware of two things that have changed this, firstly the Energia Arduino compatible IDE I mentioned here which allows me to use the Stellaris as an Arduino alike without having to learn a new IDE and secondly SLLogicLogger which allows you to use the Stellaris as a 10MHz 8 channel SUMP compatible logic analyser.

All you need is the Stellaris, the SLLogicLogger firmware, the Logic Sniffer OLS client and some way to load the firmware onto the Stellaris, I used the multi-platform toolset lm4tools.

logicsniffer

Procedure for setting it up using Linux

Firstly you will probably want to add a udev rule so that a normal user account can access the USB device.

eg. Create a new file named: /etc/udev/rules.d/61-stellapad.rules
containing:

SUBSYSTEM==”usb”,ATTRS{idVendor}==”1cbe”,ATTRS{idProduct}==”00fd”,MODE=”0666″

Now get the things we need:

git clone https://github.com/utzig/lm4tools.git
wget http://www.fischl.de/arm/sllogiclogger_logic_analyser_for_stellaris_launchpad/sllogiclogger.2012-12-24.tar.gz
wget http://www.lxtreme.nl/ols/ols-0.9.6.1-full.tar.gz

Build lm4flash:

cd lm4tools/lm4flash
make

Unpack SLLogicLogger:

tar zxvf ../sllogiclogger.2012-12-24.tar.gz

Make sure the Stellaris is connected and upload the sllogiclogger.bin file to it:

./lm4flash sllogiclogger/sllogiclogger.bin

You will get a response similar to:

Found ICDI device with serial: 0E101F65
ICDI version: 9270

Unpack LogicSniffer in a suitable location:

tar zxvf ols-0.9.6.1-full.tar.gz

Copy the SLLogicLogger plugin to the LogicSniffer plugins directory:

cp /path/to/unpacked/sllogiclogger/ols.profile-SLLogicLogger.cfg /path/to/logicsniffer/plugins/

Now run run.sh to start LogicSniffer:

./ols-0.9.6.1/run.sh

Click the button to start capture and set the Connection details as below (click to enlarge):

logicsniffer setup

If you get an error when setting the port that says “There is an incompatible JNA native library installed on this system” close LogicSniffer, edit run.sh and add -Djna.nosys=true to the last line after $MEMSETTINGS so it reads:

java $MEMSETTINGS -Djna.nosys=true -Dnl.lxtreme.ols.bundle.dir=”$PLUGINDIR” -DPlastic.defaultTheme=SkyBluer -cp “$CLASSPATH” nl.lxtreme.ols.runner.Runner

Open LogicSniffer again and it should let you set the port now.

Click Capture to return to the main screen and start capturing data. The eight pins from PB0 to PB7 on the Stellaris can be used as inputs but note that PB0 and PB1 are limited to 3.6 V, PB2 to PB7 are 5 V tolerant.

That’s it, enjoy your $5 logic analyser.

 

2 thoughts on “Using the Stellaris Launchpad as a Logic Analyser

  1. impressive!
    does it only work for the logic signal or does it also preserve the shape of any input signal (as long as it’s < 3.6/5V?
    Can it be extended to more that 8 input channels?

Leave a Reply

Your email address will not be published. Required fields are marked *

Notify me of followup comments via e-mail. You can also subscribe without commenting.