节点文献
嵌入式系统软件定时器的扩展与应用管理
Extension and Application Management of Embedded System Software Timer
【摘要】 设计了一种软件定时器管理方法,以结构体的形式设计一种软件定时器节点的数据结构,使用一个静态分配的软件定时器节点数组来定义所有的定时任务。在前后台形式的嵌入式软件系统中,前台硬件定时器以固定的时间间隔触发中断,触发MCU执行硬件定时器中断服务程序,后台主循环体中执行软件定时器管理程序,完成对各个软件定时器节点的处理。提供了一系列API接口,通过调用这些API,可以启动、停止或重启单次定时、多次定时和循环定时,实现了这三种类型的定时应用。
【Abstract】 In the paper,a software timer management method is designed.A data structure of a software timer node is designed in the form of a structure,and all timing tasks are defined using a statically distributed software timer node array.In foreground-background embedded software systems,the foreground hardware timer triggers an interrupt at a fixed interval,then triggers the MCU to execute a hardware timer interrupt service routine.A software timer management program is executed in the background main loop body to complete the processing of each software timer node.A series of API interfaces are provided.By calling these APIs,you can start,stop or restart single-timed,multiple-timed and cycle-timed.You can achieve the applications using the three timing methods.
- 【文献出处】 单片机与嵌入式系统应用 ,Microcontrollers & Embedded Systems , 编辑部邮箱 ,2018年10期
- 【分类号】TP311.52
- 【被引频次】6
- 【下载频次】145