Menu

#5 Option to save JLink scripts to disk

1.0
wont-fix
None
2015-06-30
2015-01-20
Jock Murphy
No

Please provide an option to write the generated JLink scripts to disk so that they may be incorporated in a script or on a platform not supported by RKNRFGO

Discussion

  • Jock Murphy

    Jock Murphy - 2015-05-13

    Is this being considered?

     
  • Roland King

    Roland King - 2015-05-15

    The use of JLinkExe as a sub-process with script files to drive it is slowly going away. v2 should eliminate it entirely and talk directly to the segger, for better performance and the ability to add in more of the functions the official Nordic version has.

    So there won't be any scripts to write. Not that it would have helped much anyway, the scripts currently reference on-the-fly app-generated temporary files which are created just before the call out to JLinkExe.

    if you want to incorporate a programming step on another platform there's a number of JLink script files posted around the web which would make a better starting point.

     
  • Roland King

    Roland King - 2015-05-15
    • status: open --> wont-fix
     
  • Jock Murphy

    Jock Murphy - 2015-06-30

    Just so that people are aware, I wrote a little bash script to capture the files that RKNRFGO generates.

    It generates a JLink script that looks something like this:

    // JLinkExe script for programming nrf51822 wipe then program
    power on
    st
    speed 1000
    // reset the device
    r
    // NVIC CONFIG EEN (erase enabled)
    w4 4001e504 2
    // NVIC ERASEALL (erase all flash including UICR)
    w4 4001e50c 1
    sleep 1000
    r
    // NVIC CONFIG WEN (enable writing)
    w4 4001e504 1
    r
    sleep 1000
    // run the loadscript loads
    loadbin Section0.791iy0qs.bin 0x00000000
    loadbin Section1.YF1g5vlS.bin 0x00001000
    loadbin Section2.8SYeQhDj.bin 0x00016000
    
    // reset and quit
    sleep 1000
    r
    q
    

    and calls it with a command line like this:

    [path to JLinkExe] [script file name] -if swd -device nrf51822 -SelectEmuBySn [segger serial number]
    
     

Log in to post a comment.