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.

TMS320F2800156-Q1: Default value for OSCCLKSRCSEL in the CLKSRCCTL1 Register

Part Number: TMS320F2800156-Q1

Tool/software:

Hi

I'am using F2800156 for motor control.

When in debug situation ,I find the default value for OSCCLKSRCSEL in the CLKSRCCTL1 register is 0x02, not 0x00 as the spec says.

I use a breakpoint before the clock setting to test the default value.

Pls. check if the spec is a typo, or any other suggestion?

Regards

Arrow

  • Below is the memory brower window shows

    FYI

  • Hi Arrow,

    I use a breakpoint before the clock setting to test the default value.

    Are you checking this in the Boot ROM? The Boot ROM initializes INTOSC2 to be the clock source, as confirmed below on an F2800157 unit.

    Best,

    Matt

  • Hi Matt

    I'm not checking this in the Boot ROM. I check this in the tidm_02012_ecompressor project in motorcontrol_sdk_5_03.

    The default reset value is 0x02 when connected with CCS.

    Regards

    Arrow

  • Hi Matt

    I test the same project as you. And put a break point before clock setting, I get the same result.

    The default value is still not 0x00 as spec shows.

    Regards

    Arrow

    default
  • It's very strange that when I download the program [CPU1_FLASH configuration], the default value will change to 0x02 immediately.

    Is there anything releative with my debug configuration?

    But if I change to CPU1_RAM configuration, the default value will stay with 0.

  • Hi,

    I suspect it may be residue leftover from a previous CCS debug session. If you refer to the GEL files executed when starting a debug session (ccs1281\ccs\ccs_base\emulation\gel\f2800156.gel), the memory map is initialized in the f2800156_Memory_Map() function. There, you can see that the CLK_CFG_REGS are not touched by the initialization.

    Can you try putting the device into wait boot and see if the OSCCLKSRCSEL is set to 0x0?

    Best,

    Matt

  • Hi Matt

    I use offline mode and find that the default value of OSCCLKSRCSEL is 0x0.

    But how to run the program in CCS online with a initiazation value of 0x0 of OSCCLKSRCSEL?

    Like changing the .gel file? If possible, how?

    Regards

    Arrow

  • Hi Arrow,

    It's very strange that when I download the program [CPU1_FLASH configuration], the default value will change to 0x02 immediately.

    Is there anything releative with my debug configuration?

    But if I change to CPU1_RAM configuration, the default value will stay with 0.

    Can you verify in the on-chip flash tool (Tools > On-Chip Flash) which clock source the flash plugin is using? Based on above it seems like flash plugin may have set the clock source to INTOSC1.

    Best,

    Matt

  • Hi Matt

    The  on-chip flash tool shows the INTOSC2 is used.

    Can you try the demo project to see if this is the same happens to you ?

    Regards

    Arrow

  • Hi Arrow,

    Yes, I can replicate it when programming a project to the flash. It looks like the flash plugin is using INTOSC1 as the clock source, which is not intended. We're looking into this issue and will provide an update once a resolution is found.

    I will also say that the device correctly configures the OSCCLKSRCSEL register to 0x0, this is a separate issue with the flash plugin.

    Best,

    Matt

  • Hi Matt

    Yes. As I said before ,the default configuration of OSCCLKSRCSEL in offline mode is right. Difference just happens in debug mode.

    Can I get the notice when this is fixed?

    once

    Regards

    Arrow

  • Hi Arrow,

    Yes, I was just making it clear that the device is adhering to the specifications. The flash plugin in CCS is incorrectly configuring the device to use INTOSC1, although there are no apparent issues with the flash plugin using INTOSC1 for program loading purposes at the moment. 

    I will update this thread once a fix to the flash plugin has been made. Thank you for notifying us of this issue, we appreciate it a lot!

    Best,

    Matt

  • Hi Arrow,

    I discussed this issue in detail with my colleagues. There is an underlying HW limitation preventing INTOSC2 from being used by the flash plugin, which is why INTOSC1 is being configured (see the excerpt from the F280015x errata below). Therefore, it is recommended for the user to set the clock settings in the application themselves before execution and/or perform a device reset to clear the clock register.

    Best,

    Matt