This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Uniflash 2.1.0 autorun after programming

Other Parts Discussed in Thread: TMS320C28345, UNIFLASH

Hello,


I currently use the TMS320C28345 demo board.

I have connected an external memory and developped a code to boot from the external memory.

It works on CCS v5.3 on debug mode ; I load the program on RAM and then I execute it to write on the external memory.

I'd like to use Uniflash to do that.

The problem is that, after programming with Uniflash, the code doesn't execute.

What can I do ? Is it possible to autorun after programming with Uniflash ? Do I need to change the source code on CCS ?

Thank you for your help.

  • Metthieu,

    You can use the UniFlash command line interface for this purpose. The command line tool supports a few different target operations that you can invoke after program load.

    Here is the description of the targetOp parameter:

    "-targetOp" is use to interact with the target after program loads. Specified multiple target operation arguments will be executed in order.
          
            The current supported operations are:
              1) "reset" - resets the target
              2) "restart" - issues a restart on the loaded program
              3) "run" - run the target core asynchrononously (ie; does not wait for a halt)

    Please test this out and let me know if these options work for what you need. It is also possible to extend the command line tool (via DSS) to add additional commands as well.

    Thanks,

    Ricky

  • Hello Ricky,


    Thank you for your answer.


    I don't find the command line on the GUI ; can you tell me how to do ?

    I work on Windows and I found the uniflash.bat but I don't know how to change and the wiki I found about it didn't help me.

    Thank you again.

  • Matthieu,

    To run the UniFlash command line in Windows, first open a Windows command prompt. One way to do this is to type in 'Windows key + R' to open the Run dialog, type in 'cmd' (without the quotes), and click enter.

    This will open up a command prompt window. Now, in the command prompt, go to the directory where you installed UniFlash:

      cd <pathtoUniFlash>

    There should be a uniflash.bat file here, type 'uniflash' to invoke it. Without any parameters, this will bring up the command line tool's help page, with all of the arguments it supports. To perform a program load, and run the target, execute a command that looks something like this:

      uniflash -ccxml <pathToYourCCXML> -program <pathToYourProgram> -targetOp run

    Please let me know if you want me to clarify any of these steps.

    Thanks,

    Ricky

  • Hello Ricky,


    Thank you for your answer.

    I succeeded in executing uniflash by the command line in Windows.

    When I launch it, I see the following text:

    ***** Texas Instruments Universal Flash Programmer *****

    <START: 17:56:15 GMT+0100 (CET)>

    > Configuring the Flash Programmer with the given configuration ...

    > Flash Manager is configured for the following part: TMS320C28345

    SEVERE: Option not found

    Then, it is written that Option is not found is the file uniFlash_main.js#243

    Thank you for your help.

  • Matthieu,

    Are you sure you are running UniFlash v2.1? I am checking my version of v2.1, and I see that there should be a fix for the problem you are seeing.

    The underlying problem is that the C28345 does not have Flash memory, and the command line tool tries to set an option that is only available on Flash targets. But starting with v2.1, the command line tool should detect if the option is available first before setting it.

    If you are running v2.1, can you attached the following file for me to look at?

    \uniflashv2\ccs_base\scripting\examples\uniflash\cmdLineuniFlash_main.js

    Thanks,

    Ricky

  • Hello Ricky,

    I have well the version of v2.1.0.


    I tried again this morning and I have a new problem.

    ***** Texas Instruments Universal Flash Programmer *****

    <START: 09:01:50 GMT+0100 (CET)>

    > Configuring the Flash Programmer with the given configuration ...

    > Flash Manager is configured for the following part: TMS320C28345

    > Connecting to the target for Flash operations ...

    > Connected.

    SEVERE: Target is not connected or does not support current Flash operation.

    It's written problem on the following file uniFlash_operation.js#43, I attached the file.

    Thank you for your help.

  • Hello again Ricky,


    To complete my previous message, I'd like to tell you that I can't program by command line window because TMS320C28345 has no internal flash.
     But I succeeded in programming by uniflash GUI (Programs loading finished.) and I could verify the program by command line Window, it's ok.

    The problem is that when I run the program by command line, it's written :

    > Running target.
    <END: 10:35:04 GMT+0100 (CET)>


    and the program loaded is not launched.

    The "restart" option is not working.

    Have you any idea about the problem ?

    Thank you for your help.

  • Matthieu,

    Since you are using a non-Flash target, it might make sense to use loadTI instead. In your command prompt, go to the following directory instead:

      <installDir>\uniflashv2\ccs_base\scripting\examples\loadti\

    To run loadti, give it the following parameters:

      loadti -c <pathToCCXML> <pathToProgram>

    This will load the program and start running it.

    Please test this out and let me know if it works better for you.

    Thanks,

    Ricky

  • Hello Ricky,


    Thank you very much, it works fine with loadTI :)

  • Hello Ricky,


    I have another problem but this time, it's with CCS.

    In fact, I'm using an 256kB external memory and I'd like to load a program of 250kB in it.

    With my techniques, I need to put a table of data in .out build by CCS. For that, I have to resize the memory section (384kB available on SARAM H and 128kB on SARAM L).

    The problem is that when I put the table in static section (.h), the .ebss and .cinit is filled approximately at the same time and I can't put the whole table, even if I split the sections.

    I have also tried to put the table in main.c but the size of local variable memory is not big enough.

    Have you any idea to solve this problem ?

    Thank you very much for your help.

  • Matthieu,

    It might make sense to open another thread to discuss this new issue. This way, you will get the more relevant people looking at the topic.

    Thanks,

    Ricky