如何采用SysTick来做定时器-1 硬件电路配置
这里还是借用前面LED电路我就不贴图片。
2 时钟说明
SysTick和HCK的时钟频率是一样的库函数代码如下
/**
*@briefInitializeandstarttheSysTickcounteranditsinterrupt.
*
*@paramticksnumberofticksbetweentwointerrupts
*@return1=failed,0=successful
*
*Initialisethesystemticktimeranditsinterruptandstartthe
*systemticktimer/counterinfreerunningmodetogenerate
*periodicalinterrupts.