Skip to content
This repository has been archived by the owner on Sep 15, 2022. It is now read-only.

Running on lk devices

Rico Wind edited this page Oct 27, 2015 · 3 revisions

Setup

There are a few steps in getting us going on the lk devices. First we need a few tools and compilers:

gcc:

sudo apt-get install gcc-arm-none-eabi

If you intend to debug code, install gdb. There is a bug where the docs have the same name as the normal gdb (see https://bugs.launchpad.net/ubuntu/+source/gdb-arm-none-eabi/+bug/1267680 ) - so we force it to overwrite. If you for some reason don't want to overwrite the normal gdb man pages you can compile gdb for arm from scratch)

gdb:

sudo apt-get install -o Dpkg::Options::="--force-overwrite" gdb-arm-none-eabi

ST link installation:

  • Download stlink tool (called firmware upgrade on their site, currently STSW-LINK007) from st tool.
  • Install udev rules according to readme.txt (in root of downloaded zip)
  • Unplug the device and plug it back in to apply rules
  • Start STLink tool to update firmware

Openocd is already pulled down as part of gclient runhooks - please make sure that you did the changes from above - otherwise openocd will not run unless run as sudo.

You should now be able to run:

tools/openocd.sh

which should connect to the device