Hello,
In Ride7 (7.01.0002) I see no timing changes when I change crystal frequence in the simulator.
In setup I chose PLLCLK as system clock source and its source is the HSE.
No matter what I do the simulator still run on 8MHz as system clock.
What am I doing wrong?
Regards
/Chris
my setup:
void RCC_Configuration(void)
{
/* RCC system reset(for debug purpose) */
RCC_DeInit();
/* Enable HSE. HSE is 12MHz on target board .*/
RCC_HSEConfig(RCC_HSE_ON);
/* Wait till HSE is ready */
HSEStartUpStatus = RCC_WaitForHSEStartUp();
if(HSEStartUpStatus == SUCCESS)
{
/* HCLK = SYSCLK. HCLK defines the AHB clock */
RCC_HCLKConfig(RCC_SYSCLK_Div1);
/* PCLK2 = HCLK */
RCC_PCLK2Config(RCC_HCLK_Div1);
/* PCLK1 = HCLK/2 */
RCC_PCLK1Config(RCC_HCLK_Div2);
/* Flash 1 wait state. must be set to 1 when sysclock is set to 48MHz */
FLASH_SetLatency(FLASH_Latency_1);
/* Enable Prefetch Buffer for faster CPU operation */
FLASH_PrefetchBufferCmd(FLASH_PrefetchBuffer_Enable);
/* PLLCLK = 12MHz * 4 = 48MHz */
RCC_PLLConfig(RCC_PLLSource_HSE_Div1, RCC_PLLMul_4);
/* Enable PLL. */
RCC_PLLCmd(ENABLE);
/* Wait till PLL is ready */
while(RCC_GetFlagStatus(RCC_FLAG_PLLRDY) == RESET)
{
}
/* Select PLL as system clock source */
RCC_SYSCLKConfig(RCC_SYSCLKSource_PLLCLK);
/* Wait till PLL is used as system clock source */
while(RCC_GetSYSCLKSource() != 0x08)
{
}
}
}
Last edited by chrisys (2008-09-10 08:21:03)