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.

on-chip flash clock configuration not working

Hi,

I have a legacy project of DSP 28335 constructed in CCS3.3 that runs from flash, and I migrated it into CCS5.4, the code compiles and runs but the PWM frequency is not what I want, and I think it is because the clock configuration not working.

In the Dubug mode, On-Chip Flash window, I set CLKINDIV=2 PLLCR=6, then I load and run the program, and I find that instead of 4kHz PWM I get 6kHz, which indicates that the actual clock is 1.5 times faster (likely CLKINDIV=2 PLLCR=9). To verify my thought, I run Scripts->Set PLL Ratio->OSCCLK_x6_divided_by_2, and I see the PWM being right 4kHz, which confirms that the On-Chip Flash clock configuration is not working. After I cycle the power, as you would expect, the PWM is back to 6kHz.

Did I miss anything in setting the on-chip flash clock? Is there any piece of code that I need to modify, in addition to what I do in On-Chip Flash Programmer, in order to change the clock?

Thanks,

Yang

  • Hi Yang,

    Yang Wang7 said:
    In the Dubug mode, On-Chip Flash window,

    I'm wondering how you are getting to this Window. Can you provide a screenshot?

    Thanks

    ki

  • Hi Ki,

    Thanks for getting back to me. I ended up calling InitPll(6,2) at the beginning of the main().

    But it would be nice to figure out how to set the PLL through CCS, so below is the screen sho, am I doing anything wrong? Thanks.

    Yang

  • Note that if you are going to set the option via the screenshot above, make sure you press the "Remember My Settings" button to apply to the next debug launch. Otherwise it will simply apply the settings for that current debug instance and then go back to the default on the next debug instance.