arduino/Arduino — pull request #2172 by teixense (2014-07-09 12:50:32+00:00)
Title: Change millis() / micros() to use Systick on Tiva based boards

I want to sugest a change in the milis()/micros() fuctions

I'm realy don't exacly know how to read code in direct access coding but i belive millis() uses micros() to count wich uses TIMER5 right?

Well i think this is a big waste of a timer wich can be used for PWM, pulse measuring or sometigh else since Tiva has a dedicated timer for that, the system tick.

i use this to simulate millis()
void SysTickbegin(){
SysTickPeriodSet(F_CPU/1000);// for miliseconds, F_CPU/1000000 for microseconds
SysTickIntRegister(SycTickInt);
SysTickIntEnable();

}
void SycTickInt(){
milis++; //micros++ if period set to F_CPU/1000000
}

it's also possible to use the Tiva RTC for this since it's possible to get the 1/32768 ticks but it would have a error less than 0.3 micro seconds each microsecond.
This would be make possible even to use the milis() as a RTC counter and would probably be a better option.