i am current working on ADSP BF548 custom board, I am able to set the PLL CTL and PLL DIV Register. However, I am unable to check the SCLK values in my code; is there a way to do so? I've attached my code for reference.
Please assist me since I too want to write code for the spi protocol.
ADI_SYSCTRL_VALUES sys_cntrl_write;
ADI_SYSCTRL_VALUES sys_cntrl_read;
// Set CCLK = 400 MHz, SCLK = 133 MHz, voltage to 1.25v
sys_cntrl_write.uwPllCtl = 0x2000;
sys_cntrl_write.uwPllDiv = 0x0003;
sys_cntrl_write.uwVrCtl = 0x40EB;
bfrom_SysControl ( SYSCTRL_READ | SYSCTRL_PLLCTL | SYSCTRL_PLLDIV |
SYSCTRL_VRCTL | SYSCTRL_INTVOLTAGE, &sys_cntrl_read, NULL );
printf("Before Set PLLCLT Reg : 0X%X\n",sys_cntrl_read.uwPllCtl);
printf("Before Set PLLDIV Reg : 0X%X\n",sys_cntrl_read.uwPllDiv);
printf("Before Set VRCTL Reg : 0X%X\n",sys_cntrl_read.uwVrCtl);
bfrom_SysControl( SYSCTRL_WRITE | SYSCTRL_PLLCTL | SYSCTRL_PLLDIV |
SYSCTRL_VRCTL | SYSCTRL_INTVOLTAGE, &sys_cntrl_write, NULL);
bfrom_SysControl ( SYSCTRL_READ | SYSCTRL_PLLCTL | SYSCTRL_PLLDIV |
SYSCTRL_VRCTL | SYSCTRL_INTVOLTAGE, &sys_cntrl_read, NULL );
printf("After Set PLLCLT Reg : 0X%X\n",sys_cntrl_read.uwPllCtl);
printf("After Set PLLDIV Reg : 0X%X\n",sys_cntrl_read.uwPllDiv);
printf("After Set VRCTL Reg : 0X%X\n",sys_cntrl_read.uwVrCtl);
results from the board :