what does this line mean in trace32 scripting and is there a better way to understand .cmm scripts of trace32?

30 Views Asked by At

FLASH.auto off --> I need to know what does this line does.

so we execute first a .cmm script and at the end of the script there is a line saying FLASH.Auto ALL this.

after this line we load our elf's and the we enter another .cmm scripts where the contents are

FLASH.auto off

r.s IP _start

sys.o.DUALPORT ON

during this execution, I am getting an error saying "no license available[0x0001],session limited to 50 practice commands from script." " flash erase error"

any Idea on how to solve this?

1

There are 1 best solutions below

0
Holger On

With FLASH.AUTO ALL you allow the writing to all Flash sectors defined in FLASH.List. So when you load your ELF file afterwards, your application and data gets marked to be written to the flash after one of the following events:

  • Go
  • Step
  • FLASH.AUTO off

So FLASH.AUTO off stars the actual modification of your Flash memory. The pair of FLASH.AUTO ALL and FLASH.AUTO off will first read all the affected flash sectors, then modify them according to your ELF file, and then stores the resulting data to affected sectors of your flash memory.

The error message "no license available[0x0001],session limited to 50 practice commands from script." means that you're using TRACE32 with its internal instruction set simulator, while you don't own a license for it. Since the simulator does not have any flash (normally), FLASH.AUTO has no effect here. To solve the error buy a license.

"flash erase error" sounds that flashing somehow failed. If you have written a simulator model of your flash, I recommend checking that. Otherwise, I recommend to simply disable the FLASH.AUTO commands when you're working with the simulator. E.g. like this

IF !SIMULATOR()
     FLASH.AUTO off