Summary

ATM i have not tested flash and debugging, just make configuration.
For everything else, all is working, code completion with doxygen, build is ok and post-build create necessary .bin and .hex files.
Should works under linux without problem, just get a toolchain, and build the two tools “st-util” and “st-flash”, sources at bottom

Debugger configuration

  • Settings → Debugger → GDB/CDB Debugger → Create config “ARM”
  • Select ARM in left pane
Executable pathC:\Program Files (x86)\GNU Tools ARM Embedded\4.8 2014q2\bin\arm-none-eabi-gdb.exe
Debugger initialization commandstarget extended-remote localhost:4242

Toolchain compiler configuration

  • Settings → Compiler → “GNU GCC for ARM”
  • Then <Set as default>
  • Set Toolchain Executables
Compiler install directoryC:\Program Files (x86)\GNU Tools ARM Embedded\4.8 2014q2
C compilerarm-none-eabi-gcc.exe
C++ compilerarm-none-eabi-g++.exe
Linker for dynamic librariesarm-none-eabi-gcc.exe
Linker for static librariesarm-none-eabi-ar.exe
DebuggerSelect the ARM one
Make programmake.exe

Conversion

  • Project → Build options → pre/post build steps
  • Check “Always execute even if target is up to date”
  • Post-build :
arm-none-eabi-objcopy -O ihex bin\Debug\shell.elf bin\Debug\output.hex
arm-none-eabi-objcopy -O binary bin\Debug\shell.elf bin\Debug\output.bin
cmd /c arm-none-eabi-objdump -x --syms bin\Debug\shell.elf > bin\Debug\shell.dmp

Flash

  • Tools+ → Configure Tools → New
Tool nameSTM32 Flash Debug
Command lineC:\Users\Dashie\dev\ARM\stlink-20130324-win\bin\st-flash.exe write bin\Debug\output.bin 0x08000000
Working directory$(PROJECT_DIR)\
Output toTools output window

GDB Bridge

The bridge can be used as a tool too, launching it using Tools+ menu and then starting debugging in Code::Blocks, which will use “extended-target” remote to connect to the bridge.

  • Tools+ → Configure Tools → New
Tool nameSTM32 GDB Bridge
Command lineC:\Users\Dashie\dev\ARM\stlink-20130324-win\bin\st-util.exe
Working directory$(PROJECT_DIR)\
Output toTools output window