J-Link Commander "savebin" command

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

  • J-Link Commander "savebin" command

    I am using IAR EWARM with a J-Link probe. I have a C-SPY macro that reads 24k 4-byte values out of

    target memory and writes them to a file on the PC, using "__readMemory32" and "__fmessage", which

    takes about 45 seconds to run. I would like to make a faster version using the "savebin" command from

    J-Link Commander. When I try it the command in its own separate window while IAR is executing, it runs,

    but leaves no output file. Does anyone have a working example of this? Thanks!
  • Never mind, savebin works just fine.

    Never mind, savebin works just fine, I was trying to create the file in C:\, which causes Windows to ask if you want to apply administrator privileges, but the prompt was suppressed I guess, so I got no error message nor chance to enter a password. I didn't have "immediate" write access (or whataver you want to call it) to the output file directory that I specified :cursing: .



    Now I am looking for a binary to hex file converter to process the binary file and output one 32-bit hex word per line. Then I can select the whole file and paste it into a column in Excel. Or is there a way to read the binary file straight into an Excel column? Any suggestions appreciated... :thumbsup:
  • Sporadic "savebin" operation?

    I have a windows batch file that executes two j-link script files. The first script reads a pointer out of RAM on my Atmel AT91SAM9XE512 development kit. The second script is created by a "C" executable that uses the pointer to create a script that reads data out of 13 areas in my SDRAM starting from the pointer. Then this second script is executed.



    The batch file always seemed to work on a PC with IAR EWARM version 6.40.2.3992/6.4.4.2356, SEGGER software J-Link ARM V4.68 installed, and an IAR J-Link ARM V8.0 USB debugger probe (yellow). When using different versions of these on another PC and on a laptop (IAR EWARM 7.20.2.7431/7.1.1.3263, SEGGER J-Link ARM V4.78g, J-Link V4.94h, or NONE installed, Atmel SAM-ICE 2012.08.02 (blue), I get intermittent problems.



    Sometimes I get windows and/or Segger and/or IAR error windows which cause the batch file to cease operations. Sometimes the batch file runs through but the data in the uploaded files is garbage. I know that at the end of a j-link script file, my processor resets. So I do a halt instruction first ("h") to stop the processor before it gets into the SDRAM initialization or the memory tests, which will screw up the data. Also I try to not be running very many other windows applications so that the batch file can run as quickly as possible. Still, every 4th time or so, error messages or bad data. The batch file is run after hitting a break in IAR.



    Could the different versions of IAR, SEGGER, and J-Link probes be affecting this operation? Any suggestions or things to try? I am just running SEGGER j-link script commands from a windows batch file while in IAR at a break. There is not much else I can think of to try. I am using this to read out a ton of memory which I port into Excel for data examination. My batch file produces the hex data files with no user action required. I had previously used the IAR Save Memory feature, but you have to enter start address, end address, and filename each time. I am reading out 13 files so this is too much of a pain. I had also tried the IAR C-SPY macros to dump out the data. This works fine but is excruciatingly slow for some reason, taking about 8 minutes to do the 13 files, while the "savebin" batch file technique takes maybe 45 seconds. Each file is a megabyte long.



    Any ideas or experience with any of this? Thanks - Rolf Anderson
  • Hi,

    In general, J-Link script files should work with all combinations (new / old models and new / old versions of the J-Link software).
    We need a more detailed problem description in order to help you here.

    Can you please describe step by step what you are exactly performing and what issue pops up?
    Does a error pops up? If yes, which one?
    Does a script file proceed successfully but somehow it seems that some commands have not been performed correctly (e.g. savebin did not work and did not output an error).
    Does the issue pops up without using the IAR EWARM, too? Just to strip down the issue. Small setup which shows the issue is the easiest way to find a solution.

    Best regards
    Erik
    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.