Category: Electronics
Hits: 4448

CC3200-LaunchXL is a great launchpad from TI which combines an ARM core and on-chip WiFi with an accelerometer and contactless temperature sensor and a very convenient debug interface. What is more amazing is that all these come with a 30$ price!

This guide will help you get started with your CC3200-Launchpad in Linux.


First some notes:

NOTE: This guide is for kernel versions newer than 3.12 and is tested on Ubuntu 15.1. To make things really simple this guide is based on switching to root user only for a short time to complete the installation process. This may cause security issues for some users so please be aware when using this guide and immediately exit the root user after you're done with installations.

I started my own board using a combination of this guide:
, this guide:
and a post from here:

but the process seemed to be too complicated and since I know that many people own a Linux with a kernel newer than 3.12, I created this much simpler and easier to read guide.

First download the software development kit (SDK) from TIs website:

You'll get a windows executable which obviously you can't directly run under Linux! Use wine to install it:
wine CC3200SDK-1.0.0-windows-installer.exe

wine will install sdk under ~/.wine/drive_c/ti/CC3200SDK_1.0.0
I just cut the CC3200SDK_1.0.0 folder and pasted it in my home directory. I also changed the name from CC3200SDK_1.0.0 to CC3200.
so now the sdk lies in ~/CC3200 folder.

Next thing you'd want to do is to give access to the on-board FTDI chip which is used both for programming the board (JTAG emulator) and communicating through Virtual Serial Port. It's better to completely change to the root user from this point on:
If you got an authentication error, first set a password for your root:
sudo passwd root

and then switch to the root user:

Please pay attention that to make things look simple I've used "~" to show the home folder which for me is /home/sina/. After switching to root, "~" will not work anymore and you have to paste your own home folder location (or wherever your SDK is located) instead of "~".

Yes back to how you should give access to the FTDI chip. You have to set the vendor and product ID of your CC3200:

# modprobe ftdi-sio
# echo 0451 c32a > /sys/bus/usb-serial/drivers/ftdi_sio/new_id

Please pay attention that for some reason running the above echo command using sudo didn't work for me and I had to first switch to the root user by running su and then run the above commands.

Now you can connect your board to your PC. If you run this command:
# dmesg | grep tty

you should see two FTDI USB Serial devices. The last two lines should look like this:
usb 3-1.2: FTDI USB Serial Device converter now attached to ttyUSB0
usb 3-1.2: FTDI USB Serial Device converter now attached to ttyUSB1

In order to be able to compile and then debug programs for the ARM core on the CC3200 chip, you have to use arm-none-eabi toolchain. Install it simply by running:
# apt-get install binutils-arm-none-eabi gdb-arm-none-eabi gcc-arm-none-eabi libnewlib-arm-none-eabi

OpenOCD (Open On Chip Debugger) is an amazing open source tool which allows you to communicate with many devices through their JTAG port. Install it:
# apt-get install openocd

CC3200's SDK is full of features and they've already provided the necessary configuration files for openOCD. You just have to modify the file to keep the path to your SDK.
 In ~/CC3200/cc3200-sdk/tools/gcc_scripts/cc3200.cfg.

Replace the following few lines

interface ft2232
ft2232_layout luminary_icdi
ft2232_device_desc "USB <-> JTAG/SWD"
ft2232_vid_pid 0x0451 0xc32a


interface ftdi
ftdi_device_desc "USB <-> JTAG/SWD"
ftdi_vid_pid 0x0451 0xc32a
ftdi_layout_init 0x00a8 0x00eb
ftdi_layout_signal nSRST -noe 0x0020

Now if you run openocd with the following command while your board is connected to you pc:
# openocd -f ~/CC3200_SDK/cc3200-sdk/tools/gcc_scripts/cc3200.cfg

You'll see the green LED next to the micro USB port turn on and these messages will be printed in your terminal:
Open On-Chip Debugger 0.9.0 (2015-09-02-10:42)
Licensed under GNU GPL v2
For bug reports, read
adapter speed: 1000 kHz
Info : auto-selecting first available session transport "jtag". To override use 'transport select <transport>'.
Info : clock speed 1000 kHz
Info : JTAG tap: cc3200.jrc tap/device found: 0x0b97c02f (mfg: 0x017, part: 0xb97c, ver: 0x0)
Info : JTAG tap: cc3200.dap enabled
Info : cc3200.cpu: hardware has 6 breakpoints, 4 watchpoints

Okay, now you're ready to literally LAUNCH.

First exit the root user:

# exit

Go to the blinky example inside SDK:
cd ~/CC3200/cc3200-sdk/example/blinky/gcc

and make it by running:

You should see something like:

  CC    ../main.c
  CC    ../pinmux.c
  CC    ../../common/gpio_if.c
  CC    ../../common/startup_gcc.c
  LD    exe/blinky.axf

The resulted file with the extension axf is the file which will be uploaded to the RAM memory of CC3200.
Change the file ~/CC3200/cc3200-sdk/tools/gcc_scripts/gdbinit to show the location of the SDK on your computer:
target remote | openocd -c "gdb_port pipe; log_output openocd.log" -f ~/CC3200/cc3200-sdk/tools/gcc_scripts/cc3200.cfg

(Paste the location after -f flag inside the file)

Run arm-none-eabi debugger to upload your code to CC3200:

arm-none-eabi-gdb -x ~/CC3200/cc3200-sdk/tools/gcc_scripts/gdbinit exe/blinky.axf

Press the "c" key to continue. You'll see LEDs blinking and filling your heart with joy!