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.

TMS320F280039: 128 BITS ALIGNED - FLASH API

Part Number: TMS320F280039
Other Parts Discussed in Thread: C2000WARE

Dear c2000 expert,

I found that the flash api for F28003x device needs to have 128bits- aligned in reference manual, that make the flash_do_verify always failed. Can you please help me know how to make the variable to be 128-bits aligned?

I have configure thed cmd file to have 128-bits aligned, but the address of variable is not changed in map file.

CMD file as below:

/* Global shared RAM (CPU, HIC, DMA) */
RAMGS0123 : origin = 0x0000C000, length = 0x00004000

    codestart        : >  BEGIN                   ,  ALIGN(8)
    .text            : >  FLASH_BANK0_SEC3TO14    ,  ALIGN(8)
    .cinit           : >  FLASH_BANK0_SEC3TO14    ,  ALIGN(8)
    .init_array      : >  FLASH_BANK0_SEC3TO14    ,  ALIGN(8)
    .switch          : >  FLASH_BANK0_SEC3TO14    ,  ALIGN(8)
    .config          : >  DFLASH_BANK0_SEC15      ,  ALIGN(8)
    .checksum        : >  CHECKSUM
    .config_checksum : >  DFLASH_CHECKSUM
    .mfr_model_loc   : >  MFR_MODEL_FLASH
    .reset           : >  RESET                TYPE = DSECT

    .data            : > RAMGS0123
    .stack           : >  RAMM1

    .bss             : > RAMGS0123            ,  ALIGN(8)
    .sysmem          : >  RAMM0
    .const           : >  FLASH_BANK0_SEC3TO14,  ALIGN(8)

    .bss             : > RAMGS0123            ,  ALIGN(8)

C file define:

char ilbuck_SN_cfg[32] = "POWER2023_012";

The start address of arrays in map file is not 128bits aligned. 

0     0000f77f  ilbuck_SN_cfg                    

My compler version is 22.6.0.LTS

Regards,

Jack

  • Hi Jack,

    Please check the linker command file provided in C2000Ware for the flash API usage example.

    It shows the alignment of the variable. 

    Let me know if you need further help.

    Thanks and regards,
    Vamsi

  • Vamsi,

    I couldn't find any flash api example for F28003x device in C2000Ware, can you help me know where it has?

    I think I have followed the example cmd file to configure 128-bits boudary address.

    By the way, the user guide states that the pointer, pu32CheckValueBuffer in  Fapi_doVerify api, should be 128-bits aligned, but it works while it 64-bits aligned, can you please help me know why?

    Regards,

    Jack

  • Jack,

    Please find the example at C2000Ware_5_01_00_00\driverlib\f28003x\examples\flash\flashapi_ex1_programming.c.

    And the corresponding linker command file: C2000Ware_5_01_00_00\device_support\f28003x\common\cmd\28003x_flash_api_lnk.cmd.

    64-bit alignment would work - but performance would be better with 128-bit alignment.

    Thanks and regards,
    Vamsi