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.

F28xx On-Chip Flash Programmer for older CCS

Other Parts Discussed in Thread: SPRC097

Dear all,

 

I am relatively new to the DSP environment, but have spent the last 2 months playing around with it and found it is such a powerful tool.

I am currently using the Code Composer Studio version 2.12, and having trouble trying to install the F28xx On-Chip Flash Programmer.

I have installed the TMS320C2000 CCS studio 2.21 on-chip flash programmer plugin 1.12.5. But still I couldn't find it under Tools->F28xx on-chip flash programmer.

I believe this is because my CCS version is older than the 2.2x? Please correct me if I'm wrong.

If so, how can I upgrade my current CCS to 2.2x above? I have searched around to find for update patch to 2.2x but couldnt find any - is it because 2.2x is commercialised like 3.3?

 

I have tried another alternative solution using the SDFlash. However, I couldnt compile the project if it contains any "puts" or "printf" in it. Why wouldnt it allow me to do that? where as if I just compile and run it directly from the RAM it is fine. I just like the idea of having std output to my screen - easier to debug for me.

 

I would like to thank you for your help/input in advance

  • Sorry that I forgot the state the current development board.

    My current development board is eZdspTMS320F2812, made by Spectrum Digital i think.

  • Sucahyo,

    Sucahyo Tjokro said:

    I am currently using the Code Composer Studio version 2.12, and having trouble trying to install the F28xx On-Chip Flash Programmer.

    I have installed the TMS320C2000 CCS studio 2.21 on-chip flash programmer plugin 1.12.5. But still I couldn't find it under Tools->F28xx on-chip flash programmer.

    I believe this is because my CCS version is older than the 2.2x? Please correct me if I'm wrong.

    I am not sure why the plugin is not showing in the Tools menu, but you are right when you say the difference in versions may be causing this. The plug-in strictly mentions CCS2.21, therefore it may not be installed properly. 

    Sucahyo Tjokro said:

    If so, how can I upgrade my current CCS to 2.2x above? I have searched around to find for update patch to 2.2x but couldnt find any - is it because 2.2x is commercialised like 3.3?

    Unfortunately there is no upgrade path from CCS2.12 to 2.21 anymore. CCSv3.3 is still available for purchasing but, since you are beginning to work with DSPs and may not have too much legacy code developed in CCS2.12, I suggest you to try CCSv4 as it has the latest tools and bug fixes.

    For additional details about this version, download instructions and a tutorial please check the main CCSv4 page below:

    http://processors.wiki.ti.com/index.php/Category:Code_Composer_Studio_v4

    Sucahyo Tjokro said:

    I have tried another alternative solution using the SDFlash. However, I couldnt compile the project if it contains any "puts" or "printf" in it. Why wouldnt it allow me to do that? where as if I just compile and run it directly from the RAM it is fine. I just like the idea of having std output to my screen - easier to debug for me.

    The SDFlash is a good alternative to write to the eZdsp flash memory.

    However, when you say compiler errors I imagine you are having them no matter what software you use (plug-in or SDFlash) to write to the eZdsp, is that so? If this is the case, the I/O functions puts() or printf() use a lot of memory, therefore you may be having linker allocation errors. Additional details about these types of functions are shown in the page below:

    http://processors.wiki.ti.com/index.php/Tips_for_using_printf

    At last, I highly recommend checking the application note below that contains details and example projects for flash software in F2800 devices. 

    http://focus.ti.com/lit/an/spra958h/spra958h.pdf

    Hope this helps,

    Rafael

  • Hi Rafael,

    Thank you so much for the links.

    Downloaded the spra985h.pdf and printed them; now managed to flash the program I think. Below is the output of the command prompt:

    MSG: Sdtsrv.dll interface version 2
    MSG: Loaded driver sdgo2812eZdsp.dvr
    MSG: DSP reset succeeded
    MSG: Loading flash image file
    MSG: Erase flash succeeded.
    MSG: Program flash succeeded.
    MSG: Verify flash succeeded.

    When I refer back to my old CCS 2.1, and do load symbol. It doesn't seem to do what the program suppose to do.

    The program is simply a mere of:

    #include <stdio.h>

    void main (void) {
        puts("testing");
    }

    and the .cmd is:

    MEMORY
    {
    PAGE 0:    /* Program Memory */
               /* Memory (RAM/FLASH/OTP) blocks can be moved to PAGE1 for data allocation */

       OTP         : origin = 0x3D7800, length = 0x000800     /* on-chip OTP */
       FLASH       : origin = 0x3D8000, length = 0x002000    /* on-chip FLASH minus CSM locations*/
       BEGIN       : origin = 0x3F7FF6, length = 0x000002     /* Part of FLASHA.  Used for "boot to Flash" bootloader mode. */
       RESET        :origin = 0x3F8000, length = 0x001000
       
    }
     

     
    SECTIONS
    {

       codestart        : > BEGIN,       PAGE = 0
       ramfuncs         : > FLASH,       PAGE = 0 
       .text            : > FLASH,      PAGE = 0
       .cinit           : > FLASH,      PAGE = 0
       .pinit           : > FLASH,      PAGE = 0
       .switch          : > FLASH,       PAGE = 0
       .reset           : > RESET,       PAGE = 0, TYPE = DSECT /* not used, */
       .sysmem            : > FLASH,        PAGE = 0
       .stack           : > FLASH,       PAGE = 0
       .ebss            : > FLASH,      PAGE = 0
       .econst          : > FLASH,      PAGE = 0     
       .esysmem         : > FLASH,      PAGE = 0
       .cio                : > FLASH,      PAGE = 0
    }

    Seems like I'm missing a step or something since I couldnt see the puts output in the CCS Stdout.

    The algorithm file that I used for erase, program and verify is the one provided by TI which is F2812.out (didn't do any modification), and the flash file is the .out that I got from CCS. Is it true?

    For the CCSv4, I do have a version of this installed in my PC. However, I can't find the on-chip programmer as well? is it because I'm using the free version? or do I need to install a separate patch or something similar?

  • Just modify my linker file to be:

    MEMORY
    {
    PAGE 0:    /* Program Memory */
               /* Memory (RAM/FLASH/OTP) blocks can be moved to PAGE1 for data allocation */

       OTP            : origin = 0x3D7800, length = 0x000800     /* on-chip OTP */
       FLASH        : origin = 0x3D8000, length = 0x002000    /* on-chip FLASH minus CSM locations*/
       BEGIN        : origin = 0x3F7FF6, length = 0x000002     /* Part of FLASHA.  Used for "boot to Flash" bootloader mode. */
       RESET        : origin = 0x3F8000, length = 0x001000
       RAM            : origin = 0x000240, length = 0x000560
       LOWRAM        : origin = 0x000040, length = 0x000200
       RAM1            : origin = 0x008000, length = 0x001000
       
    }
     
     
    SECTIONS
    {

       codestart        : > BEGIN,      PAGE = 0
       ramfuncs         : > FLASH,      PAGE = 0 
       .text            : > FLASH,      PAGE = 0
       .cinit           : > FLASH,      PAGE = 0
       .pinit           : > FLASH,      PAGE = 0
       .switch          : > FLASH,      PAGE = 0
       .reset           : > RESET,      PAGE = 0, TYPE = DSECT /* not used, */
       .sysmem            : > RAM,        PAGE = 0
       .stack           : > LOWRAM,        PAGE = 0
       .ebss            : > RAM1,          PAGE = 0
       .econst          : > FLASH,      PAGE = 0     
       .esysmem         : > RAM,          PAGE = 0
       .cio                : > FLASH,      PAGE = 0
       .const            : > FLASH,      PAGE = 0
    }

     

    But still couldnt see the puts stdout in my CCS 2.1.

  • Sucahyo,

    Sucahyo Tjokro said:

    Seems like I'm missing a step or something since I couldnt see the puts output in the CCS Stdout.

     

    All the unitialized data sections (.stack, .bss, .ebss) should be put in RAM (check the example file <F2812_nonBIOS_flash.cmd>). Also, the lack of output in the puts() call may be due to insufficient stack or heap. Check the option in the project build options (in CCSv4, go to menu Project -> Properties -> tab C/C++ Build -> option C2000 Linker -> Basic Options). I sent before a page that talks about printf() usage, and one of the topics talks about the memory requirements:

    http://processors.wiki.ti.com/index.php/Tips_for_using_printf#Stack_Size

    Sucahyo Tjokro said:

    The algorithm file that I used for erase, program and verify is the one provided by TI which is F2812.out (didn't do any modification), and the flash file is the .out that I got from CCS. Is it true?

    Yes.

    Sucahyo Tjokro said:

    For the CCSv4, I do have a version of this installed in my PC. However, I can't find the on-chip programmer as well? is it because I'm using the free version? or do I need to install a separate patch or something similar?

    Differently from previous versions, CCSv4 has the flash programmer integrated to the debugger. Therefore after building your project and creating a target configuration file, you can simply open the debugger by going to menu Target -> Debug Active Project.

    For details please check the sections "Creating Projects" and "Debugging Projects" of the CCSv4 Getting Started Guide:

    http://processors.wiki.ti.com/index.php/CCSv4_Getting_Started_Guide

    Hope this helps,

    Rafael

     

     

  • Hi Rafael,

    Thanks for a quick reply, and really appreciate your advices.

    I have modified my cmd to put the required section into RAM. I have further modified it further to be like the following:

    MEMORY
    {
    PAGE 0:

       OTP            : origin = 0x3D7800, length = 0x000800
       FLASH        : origin = 0x3D8000, length = 0x002000
       BEGIN        : origin = 0x3F7FF6, length = 0x000002
       RESET        : origin = 0x3F8000, length = 0x001000
       M0SARAM        : origin = 0x000040, length = 0x000360
       M1SARAM        : origin = 0x000400, length = 0x000400
       L0SARAM        : origin = 0x008000, length = 0x001000
       L1SARAM        : origin = 0x009000, length = 0x001000
       
    }
     
    SECTIONS
    {

       codestart        : > BEGIN,      PAGE = 0
       ramfuncs         : > FLASH,      PAGE = 0 
       .text            : > FLASH,      PAGE = 0
       .cinit           : > FLASH,      PAGE = 0
       .pinit           : > FLASH,      PAGE = 0
       .switch          : > FLASH,      PAGE = 0
       .econst          : > FLASH,      PAGE = 0
       .const            : > FLASH,      PAGE = 0 
       .reset           : > RESET,      PAGE = 0, TYPE = DSECT /* not used, */
       .sysmem            : > L0SARAM,    PAGE = 0
       .esysmem         : > M1SARAM,    PAGE = 0
       .stack           : > L1SARAM,    PAGE = 0
       .ebss            : > L0SARAM,    PAGE = 0   
       .cio                : > L0SARAM,    PAGE = 0
      
    }

    and change my program to be the following:

    #include <stdio.h>

    int main() {
        puts("Hello, world!");
    }

    The heap size and the stack size have been modified to 0x600 and 0x400 correspondingly.

    Despite these, I still couldn't see the "Hello World" in the Stdout of the CCS after File->Load symbol-> .out

    If I click Debug -> Go main after loading the symbol, the program will automatically run/animate but no stdout is visible.

    I pressume I should have enough Heap and Stack size being set to 0x600 and 0x400.

    According to my .map file, I should have plenty for all of the program to run.

    MEMORY CONFIGURATION

                      name            origin    length      used    attr    fill
             ----------------------  --------  ---------  --------  ----  --------
             M0SARAM                 00000040   00000360  00000000  RWIX
             M1SARAM                 00000400   00000400  00000000  RWIX
             L0SARAM                 00008000   00001000  00000b68  RWIX
             L1SARAM                 00009000   00001000  00000400  RWIX
             OTP                     003d7800   00000800  00000000  RWIX
             FLASH                   003d8000   00002000  00000b1b  RWIX
             BEGIN                   003f7ff6   00000002  00000000  RWIX
             RESET                   003f8000   00001000  00000000  RWIX

    I am still using CCS 2.1 btw.

    Will re-install the latest CCSv4.

  • Just re install CCSv4.

    But after I clicked Target-> Debug active project, it doesnt allow me to debug the code.

    It asks for licenses again. I did request a free license, but seems like it is not sufficient to do this particular thing?

  • Sucahyo,

    What is exactly the message that appears asking for a license? You are trying to connect to the eZdsp2812, right? If so, a free limited license should allow you to do this.

    When you requested a free limited license did you receive a .lic file from TI and pointed CCSv4 to it? If you have any questions on this process please check:

    http://processors.wiki.ti.com/index.php/GSG:CCSv4_Running_for_the_first_time

    Once you received a license file from TI, check if the directory below contains any files with .lic extension. They may be interfering with your newly received license file.

    C:\Program Files (x86)\Texas Instruments\ccsv4\DebugServer\license

    Regards,

    Rafael 

  • Rafael,

    Yes, eZdspTMS320F2812.

    I have the free limited license, and it allows me to build the project. But once I click "Debug active project", it prompt me to put a new license on.

    The reason is: "You are not licensed to use the currently configured connection-type".

    Is it because I'm trying to connect it using XDS510 Parallel-Port PCI Emulator?

  • Sucahyo,

    I see now what may be happening. The free limited license only allows the use of embedded emulators (typically USB), however the eZdsp2812 has an embedded XDS510 parallel port emulator but CCS may be thinking it is a standalone emulator (therefore not allowed to operate with this license).

    When you configured the eZdsp, which driver did you select: <sdgo2812eZdsp.xml> or <sdgo28x.xml>? Unfortunately I don't have a board here with me, but I would try to test both configurations and see if one of them works.

    Do this test and see if one of the two configurations work.

    Cheers,

    Rafael

  • Rafael,

    Thank you very much for clearing things up.

    Currently I use sdgo2812eZdsp.xml. I will give sdgo28x.xml ago now.


    Will get back to you soon.

    Kind regards,

    Sucahyo

  • Rafael,

    Just tried the sdgo28x.xml; unfortunately same thing happened - it asks for a new license and returning the same error value.

    Apart from that, I'm just wondering how can I quickly set for example, the DS2 LED to turn off. I am aware that the DS2 is controlled by the XF, which is located in GPIOF14.

    How can I toggle the LED turning off and on at certain period? Do I need to create a structure containing all the addresses and bits?

     

    Very sorry that my knowledge in DSP is not very broad at the moment. Have programmed other microcontrollers such as ATMega8, but this seems a little different.

    Kind regards,

    Sucahyo

  • Sucahyo,

    I found an eZdsp2812 and verified it indeed does not work with the CCSv4 Free Limited License due to the reasons I mentioned before. I am still checking some other factors, but right now the two alternatives to use CCSv4 with your board are:

    - Download and install the MSP430/F28x code size limited version, since it has no restriction on the type of emulator used.

    - Get a XDS100 emulator from one of the third party vendors. Although you would spend some money (something around $80), it allows debugging code in any prototype board you create.

    Sorry for the confusion about the versions; the parallel port emulators are not as common as they used to be.

    Best regards,

    Rafael

  • Rafael,

     

    Thanks for clearing up the situation.

    Downloading the MPS430/F28x code size limited at the moment. Hopefully this will work out better.

     

    Kind regards,

    Sucahyo

  • Sucahyo,

    I will follow up with Spectrum Digital.  Basically because you are selecting the "Spectrum Digital Parallel Port/PCI emulator" CCS assumes it is a standalone emulator which is not allowed with the free limited license.  It may be that Spectrum doesn't have a way to distinguish the standalone Parallel emulator from the ones built onto some of the old eZdsp kits.  If that is the case then it is not possible to make it work with the free license and you will have to do as Rafael suggests and use the code size limited license.

    Regards,

    John

     

  • Rafael, JohnS,

     

    Thank you so much for the direction - have downloaded and installed the MPS430/F28x, worked superb.

    One more trouble that I'm having is to locate my program to the external memory XINTF zone 6 or zone 7.

    As far as I know- all I need to do is to change the configuration in the linker file. eg

    MEMORY
    {
    PAGE 0:

       BEGIN        : origin = 0x3F7FF6, length = 0x000002
       RESET        : origin = 0x3F8000, length = 0x001000
       M0SARAM        : origin = 0x000040, length = 0x000360
       M1SARAM        : origin = 0x000400, length = 0x000400
       L0SARAM        : origin = 0x008000, length = 0x001000
       L1SARAM        : origin = 0x009000, length = 0x001000
       H0            : origin = 0x3F9000, length = 0x001000
      
    PAGE 1:

        XINTF6        : origin = 0x100000, length = 0x080000
       
    }
     
    SECTIONS
    {

       codestart        : > BEGIN,      PAGE = 0
       ramfuncs         : > XINTF6,     PAGE = 1 
       .text            : > XINTF6,     PAGE = 1
       .cinit           : > XINTF6,     PAGE = 1
       .pinit           : > XINTF6,     PAGE = 1
       .switch          : > XINTF6,     PAGE = 1
       .econst          : > XINTF6,     PAGE = 1
       .const            : > XINTF6,     PAGE = 1 
       .reset           : > RESET,      PAGE = 0, TYPE = DSECT /* not used, */
       .sysmem            : > L0SARAM,    PAGE = 0
       .esysmem         : > M1SARAM,    PAGE = 0
       .stack           : > L1SARAM,    PAGE = 0
       .ebss            : > L0SARAM,    PAGE = 0   
       .cio                : > L0SARAM,    PAGE = 0
      
    }

     

    despite that, I always got the following error

    C28xx: File Loader: Data verification failed at address 0x00100000 Please verify target memory and memory map.
    Error found during data verification.
    Ensure the linker command file matches the memory map.

    Is there anything extra that I need to do?

    Configuring the pin MP/MC=1 (microprocessor) still return the same error - also booting from either H0 or FLASH. According to the data sheet, the memory XINTF zone 6 starts at 0x100000 with maximum length 0x80000, which i have configured it to be that way - did I miss interpret something?

    I'll leave the optimization a bit later, once I can get the processor to read from external ram.

  • I contacted Spectrum Digital and they provided the attached files.  These will enable the use of the older parallel port eZdsp kits with the free license for XDS100/EVMs/DSKs/eZdsp.

    SD2812eZdsp_Connection.xml goes in \ccsv4\common\targetdb\connections

    sdgo2812eZdsp.xml goes in \ccsv4\common\targetdb\drivers

     

    The next time you run CCS there should be a "Spectrum Digital eZdsp2812 Parallel Port Emulator" listed in the connection drop down of the target configuration editor.  Select it and select EZDSPF2812 for the device.

     

    Regards,

    John

     

    SD2812eZdsp.zip
  • Sucahyo,

    Your linker command file for placing code in external memory seems to be ok, but I would recommend first running the example program we provide and then tailoring it for your needs. The C281x C/C++ Header Files and Peripheral Examples (SPRC097) contains an example run_from_xintf, which you can import into CCS4 and run.

  • Thanks for the help John,

    Will do the install tonight.

     

    Aarti,

    I have tried to run run_from_xintf, but I couldn't get it going - it keeps returning

    "Data verification failed at address 0x101146. Please verify target memory and memory map"

    I tried to run this using the old CCS 2.1

     

    Will try to use CCSv4 - I remembered trying this and it returns similar error.

     

    I have tried different jumper settings, MP/Mcn = 1 and 0. Both returns the same error.

     

    Could it be my external memory is damaged?

  • Aarti,

     

    When I tried to run using CCSv4, it returned

    C28xx: File Loader: Data verification failed at address 0x00101000 Please verify target memory and memory map.
    Error found during data verification.
    Ensure the linker command file matches the memory map.

    Any idea whats causing this?

    The jumper settings are default.

  • My CCS is crashed after trying to run this.

    It says that the workspace needs to be closed because running out of memory or something similar like that.

  • Sucahyo,

    What are all your jumper settings? I am able to load that example on F2812 eZdsp without any errors using CCS 4.1.2. Are you using v4.1.2 as well?

  • Aarti,

    I am using the CCS v 4.1.2.

    Jumper settings areat default factory setting:

    JP1 is Microcomputer (2-3)

    JP7 is 0

    JP8 is 0

    JP11 is 1

    JP12 is 0

    JP9 is (1-2) PLL enabled.

    I just give it a go again and it returned the same error:

    C28xx: File Loader: Data verification failed at address 0x00101000 Please verify target memory and memory map.
    Error found during data verification.
    Ensure the linker command file matches the memory map.
    \

    any idea whats wrong?

    All I did was straight import the code. Build project and debug.

  • It is odd that the message is referring to address 0x00101000 and not 0x00100000 which is the starting address of external memory where we're allocating sections.

    Does the same error occur with JP1 set to 1-2?

    Are you able to open a CCS memory window at 0x100000 and view/modify memory there?

  • Aarti,

    I just checked the memory map, and it seems that the ZONE6 has been allocated to 0x101000. I have re-modified this to0x100000 and still got the same error for both when JP1 is set to 1-2.

    C28xx: File Loader: Data verification failed at address 0x00100000 Please verify target memory and memory map.
    Error found during data verification.
    Ensure the linker command file matches the memory

    Notice that the address is just shifted to the current configuration file.

    Do I need to do any modification at all to the code?

    How do I open the memory window and modifiy it?

    If Ii go to View -> memory, it doesn't show anything - the whole column is blocked.

  • Any help will be highly appreciated. :)