开始测试的时候PLL倍频成功,同样的源代码后来就不能倍频了,我把代码粘贴出来.
#include <stdio.h>
#include "Driver\DrvGPIO.h"
#include "Driver\DrvUART.h"
#include "Driver\DrvSYS.h"
void Delay(uint32_t x)
{
int32_t i;
for(i=0;i<x;i++)
{
__NOP();
__NOP();
}
}
int32_t main (void)
{ UNLOCKREG();
SYSCLK->PWRCON.XTL12M_EN = 1;
/* Waiting for 12M Xtal stable */
while (DrvSYS_GetChipClockSourceStatus(E_SYS_XTL12M) != 1);
LOCKREG();
Delay(200);
DrvSYS_Open(48000000);
DrvGPIO_Open(E_PORT0,E_PIN0, E_IO_OUTPUT);
while(1)
{
DrvGPIO_ClrBit(E_PORT0,E_PIN0);
Delay(200000);
DrvGPIO_SetBit(E_PORT0,E_PIN0);
Delay(200000);
}
} |