10 years, 9 months ago.

Exporting to offline compiler

Hello, I am using the NRF51822-mkit and I have trouble exporting the examples for use with an offline compiler. I tried the mbed-blinky and the BLE_LopbackUART. Compiling the examples online works fine. No compile error and the example does what it is supposed to do. Compiling them offline either using keil (v5) or using gcc doesn't work. The examples compiles but don't run.

I tried to download both hex and binary files without success.

I also noticed that the online compiler produces a much bigger hex file than the offline ones. The target adresses in the intel hex are not the same.

I assume that something must be missing somewhere or that the offline compilers are not correctly configured...

Did anybody solve that problem ?

Best regards,

Christian

Question relating to:

The nRF51822-mKIT is a low cost ARM mbed enabled development board for Bluetooth® Smart designs with the nRF51822 SoC. The kit gives access to all GPIO pins via pin headers …

1 Answer

10 years, 9 months ago.

I see that when I export nRF51822 projects from the online compiler for the GNU ARM toolchain, the Makefile created has an additional rule called merge. This rule uses srec_cat to merge the soft device with your application binary to generate combined.hex.

So to build, you would need to run.

make all merge

You will of course need to find srec_cat for your platform. I don't have any experience with that tool though. I see steps here that would probably install it on Ubuntu.

Accepted Answer

It works on windows as well ! Thank you very much.

posted by Christian Koechli 28 Nov 2014