SHARE
TWEET

Untitled

a guest Sep 13th, 2017 47 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. void ConfigPLL(void)
  2. {
  3.  
  4.   PLLCFG=0x25; //PSEL = 01, MSEL = 00101 (60MHz)
  5.  
  6.   PLLCON=0x1;
  7.   PLLFEED=0xAA;
  8.   PLLFEED=0x55;
  9.  
  10.   while(!(PLLSTAT & 0x400)){};
  11.  
  12.   PLLCON=0x3;
  13.   PLLFEED=0xAA;
  14.   PLLFEED=0x55;
  15.  
  16.   APBDIV = 0x01;  //Default is 1:4 setting this to 0x01 will make the APB 1:1 with System Clock...
  17.  
  18. }
RAW Paste Data
Top