[SOLVED] Flashing a nRF51422_xxAA with JLinkExe on OS X

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • [SOLVED] Flashing a nRF51422_xxAA with JLinkExe on OS X

    Hello,
    I'm trying to flash a nRF51422 with a binary build with the gcc tool chain. I've connected my JLink pro to the target hardware and had the following dialog with the device:


    J-Link>device nRF51422_xxAB
    Info: Device "NRF51422_XXAB" selected (129 KB flash, 16 KB RAM).
    Reconnecting to target...
    Info: Found SWD-DP with ID 0x0BB11477
    Info: Found Cortex-M0 r0p0, Little endian.
    Info: FPUnit: 4 code (BP) slots and 0 literal slots
    J-Link>r
    Reset delay: 0 ms
    Reset type NORMAL: Resets core & peripherals via SYSRESETREQ & VECTRESET bit.
    J-Link>loadbin ./kommunikationsmodul,0
    Downloading file... [./kommunikationsmodul]
    J-Link>mem 0, 16
    00000000 = 00 40 00 20 3D 05 00 00 29 0B 00 00 71 06 00 00
    00000010 = 00 00 00 00 00 00


    Looking with objdump to the content of the binary:


    build/source/kommunikationsmodul/kommunikationsmodul: file format elf32-littlearm

    Contents of section .text:
    0000 00400020 b1020000 f9020000 fb020000 .@. ............


    it shows, a difference. What was going wrong? Why don't I get some helpful error messages? Any idea, any pointers?

    Thanks in advance for any comment,
    Torsten
  • Hi,

    You are using the loadbin command which is (as the name indicates) for binary files.
    The file you are loading is an ELF file.
    ELF is not bin.

    ELF file support is planned for a future version, but I cannot give you a schedule yet.
    For now, you need to convert your ELF file into a bin file for using this command
    or converting it into a hex/mot/ etc. file in order to use the "loadfile" command.

    Please note that J-Link always expects proper file extensions.


    - Alex
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.
  • Hi Thorsten,

    Thanks for the feedback.
    So we can consider this as solved / closed. :)


    - Alex
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.