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

Troubles testing SDK examples for nRF51DK

Hello everyone!

I'm writing here becouse I'm quite new to the embedded world and I'm experiencing some troubles starting with this platform.. I must say that, since I found a severe lack of documentation, I have not a clear idea of how the things work in this nRF51DK world.

My final aim is to compile and run the rtx RTOS on which building some nice software. I'm under Linux and I'm using gcc without any IDE.

The first problem I face is that I'm not able to run the compiled blinky_rtx example: I usually merge hexes with the command

srec_cat s110_nrf51822_7.1.0_softdevice.hex -intel nrf51422_xxac.hex -intel -o combined.hex -intel --line-length=44

This command fails saying:

multiple 0x00000000 values (previous = 0xC0, this one = 0x00)

Not able to compile this example I went back to the roots: I tried to compile the plain blinky example. If I compile the version with the s110 softdevice and I merge it with the same command written before, it works perfectly... so why is the blinky_rtx not working?

I've also tried to compile the "blank" branch of the blinky example and this one doesn't work: comparing the two makefiles I've discovered that the s110 branch provides some particular flags to the compiler.. well.. how could I guess them? Is there a nice place in which I can found a documentation explaining how to compile and run the software without surprises?

Can you give me the help necessary to have the rtx running?

Thank you in advance, Francesco

Parents
  • I'm not sure why the merging fails, but you don't really have to merge them. You can flash the softdevice hex and then the application hex. If you use JLinkExe to flash the chip you can flash both hex-files with a batch script similar to this:

    echo "device nrf51822" > $BINDIR/burn.seg
    echo "speed 1000" >> $BINDIR/burn.seg
    echo "w4 4001e504 2" >> $BINDIR/burn.seg
    echo "w4 4001e50C 1" >> $BINDIR/burn.seg
    echo "sleep 100" >> $BINDIR/burn.seg
    echo "r" >> $BINDIR/burn.seg
    echo "loadbin $SOFTDEVICE_HEX 0x0" >> $BINDIR/burn.seg
    echo "loadbin $APP_HEX 0x18000" >> $BINDIR/burn.seg
    echo "sleep 100" >> $BINDIR/burn.seg
    echo "r" >> $BINDIR/burn.seg
    echo "g" >> $BINDIR/burn.seg
    echo "exit" >> $BINDIR/burn.seg
    echo "" >> $BINDIR/burn.seg
    JLinkExe < $BINDIR/burn.seg
    

    We do not currently have a complete support on GCC, but the makefiles in each of the example folders should at least compile the code out of the box. However, there have been some issues with the SDK7 makefiles, and some requires modifications to work. The GCC support is better in SDK8.

  • Alright! We would really appreciate that! You are of course welcome to ask any other questions in the forum. A nice evening for you too:)

Reply Children
No Data
Related