Computer Engineering and Applications ›› 2014, Vol. 50 ›› Issue (22): 106-110.

Previous Articles     Next Articles

Research on multi-level priority task queue scheduling strategy in TinyOS

MA Wentao, LI Shuangqing   

  1. College of Computer Science, Chongqing University, Chongqing 400044, China
  • Online:2014-11-15 Published:2014-11-13

TinyOS中多优先级任务队列调度策略研究

马文涛,李双庆   

  1. 重庆大学 计算机学院,重庆 400044

Abstract: Considering the deficiency that TinyOS FCFS scheduling strategy cannot timely response to important tasks, a scheduling strategy based on multi-level priority task queue is proposed and implemented on TinyOS. Multi-level priority task queue scheduling strategy expands original task queue from one to three priority queues and preemption mechanism is introduced, a task in the highest priority queue can preempt the task running in other queues only when it satisfies preemptive principles, task preemption only takes place between different queues, In this way the time of context switching decreases and important tasks can execute in time. Experiment results prove that this new scheduling strategy improves the response characteristic for important tasks of TinyOS efficiently without affecting the intrinsic performance of TinyOS.

Key words: wireless sensor network, TinyOS, scheduling strategy

摘要: 针对TinyOS先来先服务调度策略中重要任务不能及时响应的不足,提出一种基于多优先级任务队列的调度策略。该调度策略将原来一个任务队列增加为三个优先级队列并引入抢占机制,最高优先级队列中的任务在满足抢占原则时才可以抢占其他队列正在执行的任务,任务只能在不同队列之间发生抢占,这样既减少了上下文切换,又保证了重要任务的优先执行。实验结果表明,该调度策略在不影响原有系统性能的情况下,提高了TinyOS对重要任务的响应性能。

关键词: 无线传感器网络, TinyOS, 调度策略