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.

TMS570LS3137: 4 Binary files 4 project to be working on single bank of 1.5 MB

Part Number: TMS570LS3137
Other Parts Discussed in Thread: UNIFLASH

We have requirement to run 4 projects on the same BANK 0 of TMS570LS3137 , Does CCS allow 4 projects in single project file to with dedicating fixed FLASH memory range to each project .

And than it will be easy with breakpoints and running the 4 projects on the same Microcontroller Bank 0

following is memory range of the 4 projects with 4 bin files generated 

FIXED DECISION MAKER address             0x00000000 to 0x00007FFF

UPGRADEBLE APPLICATION address      0x00020000 to 0x000FFFFF

BOOTLODAER APPLICATION address      0x00100000 to 0x0011FFFF

UPGRADEBLE DECISION MAKER  add    0x00120000 to 0x0015FFFF

  • Hello Chandre,

    How do handle the exception vector for 4 projects? What are the relationships between those 4 projects?
  • Good Day Mr.QJ Wang ,

    Project 1 is supposed to be CRC verifier and decision maker this project 1 will have TABLE of function pointers to pass control at an EXCEPTION for PROJECT 2 ( beginning at BANK0 0x00020000), PROJECT 3(Beginning at BANK0 0x00100000) and PROJECT 4 ( Beginning at BANK0 0x00120000).

    Project 1 will be fixed and should never be erased for any reason during life time of the product so 0x00000000 to 0x00020000 , is supposed to be Fixed project that never gets erased and this project contains decision to pass the Program Counter to Project 1, Project 2, Project 3 OR Project 4 . When the CRC is confirmed for those projects the control jumps to those projects .

    When Project 2 CRC is good and control is passed to Project 2 it is dependent on Project 1 to pass the exceptions to this project 2 , Project 2 is totally independent from Project 3 and Project 4 .

    Project 3 is independent from Project 2 and project 4 but from Project 1 the exceptions will be redirect to Project 3.

    Project 4 is independent from Project 2 and project 3 but from Project 1 the exceptions will be redirect to Project 4.

    FIXED DECISION MAKER address             0x00000000 to 0x00007FFF

    UPGRADEBLE APPLICATION address      0x00020000 to 0x000FFFFF

    BOOTLODAER APPLICATION address      0x00100000 to 0x0011FFFF

    UPGRADEBLE DECISION MAKER  add    0x00120000 to 0x0015FFFF

    Psuedo code for _undef EXCEPTION that will be fixed and never be erased at address  0x0000004 

    void _Decision_Maker_Table_undef(void)
    {
    if(Region_Active == 0x4150504C)
    {
           g_ul_Interrupt_TransferAddress= APPLICATION_BASE_ADDRESS+0x04UL;
           ((void (*)(void))g_ul_Interrupt_TransferAddress)();
    }
    else if(Region_Active==0x424F4F54)
    {
           g_ul_Interrupt_TransferAddress= BOOTLOADER_BASE_ADDRESS+0x04UL;
          ((void (*)(void))g_ul_Interrupt_TransferAddress)();
    }
    else if(Region_Active==0x44454349)
    {
             _decision_Maker_interrupt_undef();
    }
    else if(Region_Active==0x44454649)
    {
              g_ul_Interrupt_TransferAddress= DECISION_MAKER_EXTENSION_BASE_ADDRESS+0x04UL;
             ((void (*)(void))g_ul_Interrupt_TransferAddress)();
    }
    }

    EXPECTED MEMORY MAP SHOULD BE LIKE BELOW

                                    0x00                            0x04                           0x08                          0x0C                         0x10                            0x14                         0x18                             0x1C
                                   _c_int00                     _undef                       _svc                           _prefetch                   _data                          reservedEntry           _irqHandler                 pc,[pc,#-0x1b0]
    0x00000FFF           DECISION_MAKE   DECISION_UNDEF    DECISION_SVC       DECISION_PRE      DECISION_DATA     DECISION_RES       DECISION_IRQ         DECISION_FIQ                 
    0x00020000           _C_INT_APP           EA03808E                   EA0389A3                 EA0380B0                EA0380CB                 EAFFFFFE              EA0301D9                 E51FF1B0
    0x00100000           _C_INT_BOOT        EA028208                   EA028B24                 EA02822A                EA028245                  EAFFFFFE               EA0281D9                 E51FF1B0
    0x00120000           _C_INT_DECFI       EA02808E                   EA0289A3                 EA0280B0                EA0280CB                 EAFFFFFE               EA02805F                 E51FF1B0
  • Hello Chandre,

    Thanks for your explanation. You can use CCS to compile your 4 projects separately, and use uniflash to program the 4 images at the same time. This is my example: I loaded 2 images to the flash using uniflash.