My question is that when a user wants to know a real clock speed using a oscilloscope, how to check it?
My board is Stellaris Launchpad(EK-LM4F120XL). It uses 16MHz osc.
From the below example,
SysCtlClockSet brings me 40MHz by literature.
At that time, I really want to confirm it whether 40MHz is real or not with Oscilloscope.
And ulPeriod resulted from SysCtlClockGet should be checked by Oscilloscope.
Would you let me know how to check it and give me a tip?
I would like to probe 40MHz and ulPeriod.
------------------------------ Example (Lab 4, workshop) ---------------------
int main(void)
{
unsigned long ulPeriod;
SysCtlClockSet(SYSCTL_SYSDIV_4| SYSCTL_USE_PLL|SYSCTL_XTAL_16MHZ|SYSCTL_OSC_MAIN);
SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOF);
GPIOPinTypeGPIOOutput(GPIO_PORTF_BASE, GPIO_PIN_1|GPIO_PIN_2|GPIO_PIN_3);
SysCtlPeripheralEnable(SYSCTL_PERIPH_TIMER0);
TimerConfigure(TIMER0_BASE, TIMER_CFG_32_BIT_PER);
ulPeriod = (SysCtlClockGet() / 10) /2;
TimerLoadSet(TIMER0_BASE, TIMER_A, ulPeriod -1);
IntEnable( INT_TIMER0A );
TimerIntEnable(TIMER0_BASE, TIMER_TIMA_TIMEOUT);
IntMasterEnable();
TimerEnable(TIMER0_BASE, TIMER_A);
~~~~ // ~~~~~