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.

TMS570LC4357: System Clock for CAN Bootloader and F021 Flash API

Part Number: TMS570LC4357
Other Parts Discussed in Thread: HALCOGEN

Hello,

I am using the TMS570LC4357 and have a few problems testing the CAN bootloader.

I used HalcoGen version 4.6 and I used the Flash API 02.01.01.

First,

System clock 100Mhz and 150Mhz works well in bootloader program. However, 200Mhz and 300Mhz or more 150MHz can not be operated.

In the Flash Erase process, Fapi_issueAsyncCommandWithAddress return value is Fapi_Status_Success.

But status check routine can not get out of an infinite loop.

while (FAPI_CHECK_FSM_READY_BUSY == Fapi_Status_FsmBusy);

while (FAPI_GET_FSM_STATUS! = Fapi_Status_Success);

This happens when the system clock exceeds 150MHz.

Does Flash API 02.01.01 not support system frequencies above 150Mhz?

Second,

When the system clock of the bootloader and the application are the same the bootloader runs the application well.

But if it is different (bootloader is 100MHz, application is 300Mhz), Application does not work.

Application seems to be out of system clock.

However, when the application is executed alone in CCSV7, the system clock is set well and the operation is good.

Thanks for easy answer.

  • Hello Kim,

    Have you changed the system clock definition in bl_config.h? The SYS_CLK_FREQ should be consistent with the HCLK.

    #define CRYSTAL_FREQ 16 //MHz

    #define SYS_CLK_FREQ 150 //MHz

    The flash is clocked by HCLK and is limited to maximum 150 MHz.

  • Hello, Wang

    I mistook SYS_CLK_FREQ for GCLK.
    I Set the Fapi_initializeFlashBanks function with the appropriate HCLK value, CAN bootloader works normally.
    Thank you for your advice.

    Thanks and Regards
    Kim.