This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

bootloader + watchdog for mbed

I am trying to modify the default mbed bootloader to include support for watchdog. I'm running with nRF51822AC (NRF51DK). My program is written with mbed classic (uses S130v1) and I'm using mbed CLI. The main issue I'm experiencing is that replacing the default bootloader that comes with mbed (s130_nrf51_1.0.0_bootloader.hex, 35K) with say, the dfu bootloader example from SDK 10 (/examples/dfu/bootloader/pca10028/dual_bank_ble_s130/) causes the device to hang and the application doesn't start. What I've done was simply to replace the default file with my newly compiled one (~41K). Is that suppose to work, or has mbed introduced some special things in their bootloader? If not, is this somehow related to predefined offsets in the target definition json file?

I am also not sure what source code was used to create the default mbed bootloader (ideally, I would just change that one). I looked at some forums and it seems like this might be the repo: github.com/.../nrf5x-dfu-bootloader, but I was not able to compile it (arm-none-eabi-gcc with osx, I get the following errors):

Scanning dependencies of target BLE_BOOTLOADER.elf
[  8%] Building C object CMakeFiles/BLE_BOOTLOADER.elf.dir/main.c.o
arm-none-eabi-gcc: error: unrecognized command line option '--c99'
arm-none-eabi-gcc: error: unrecognized command line option '--cpu=Cortex-M0'
arm-none-eabi-gcc: error: unrecognized command line option '--apcs=interwork'
arm-none-eabi-gcc: error: unrecognized command line option '--enum_is_int'
arm-none-eabi-gcc: error: unrecognized command line option '--md'
arm-none-eabi-gcc: error: unrecognized command line option '--feedback=.feedback'
make[2]: *** [CMakeFiles/BLE_BOOTLOADER.elf.dir/main.c.o] Error 1
make[1]: *** [CMakeFiles/BLE_BOOTLOADER.elf.dir/all] Error 2
make: *** [all] Error 2

If anyone went through this hassle before and managed to get a new bootloader that works with mbed's S130v1, please contact me. I really need some help on this.

Thank you!

Shay

Parents Reply Children
No Data
Related