Other Parts Discussed in Thread: TM4C123GH6PGE
Hi,
I have a Tiva TM4C123GH6PGE clocked by an external 25MHz clock module.
I am initialising the clock with...
ROM_SysCtlClockSet(SYSCTL_SYSDIV_4 | SYSCTL_USE_PLL | SYSCTL_OSC_MAIN | SYSCTL_XTAL_25MHZ);
If I run...
int speed;
speed = ROM_SysCtlClockGet();
speed is set to 50,000,000 as expected, and hoping for approximately 50MIPS
so...
If I then time how long it takes to do 20 integer increments...
int number;
pinset; //for scope
number++;
number++;
number++; etc etc
pinclear;
these 20 increments take approx 4uS, which means each increment takes 200nS, this is 5MIPS
there seem to be no references to clock cycles per instruction in the documentation
what have I done wrong?
Thanks, Richard