Time-Memory Scheduling and Code Generation of Real-Time Embedded Software

Chuen-Hau Gau and Pao-Ann Hsiung
Department of Computer Science and Information Engineering
National Chung Cheng University, Chiayi-621, Taiwan.
( RTCSA'02, March 18-20, 2000.)


With the computerization of most daily-life human amenities such as home appliances, the software in a real-time embedded system now accounts for as much as 70% of a system design. On one hand, this increase in software has made embedded systems more accessible and easy to use, while on the other hand, it has also necessitated further research on how a complex, real-time, embedded software can be designed automatically and correctly. Enhancing recent advances in this research, we propose a Time-Memory Scheduling (TMS) method for formally synthesizing and automatically generating code for real-time embedded software, using the Colored Time Petri Nets model. Our method extends previous work in three ways: (1) by allowing the specification of temporal constraints} in the system description to model real-time behaviors of software, (2) by allowing the specification of colored tokens in the system description to model different memory usages by data-types, and (3) by proposing an extended algorithm to schedule the enhanced system model and generate static code. A real-time embedded software, which is specified by a set of CTPN, is scheduled using TMS such that the schedules satisfy limited embedded memory requirements and all real-time and task precedence constraints. Finally, a portable embedded software program is generated in the C programming language using the valid TMS schedules. The proposed method was implemented in Java so that is can be installed in all kinds of embedded systems and prototypes for on-line code change to satisfy the dynamic needs of users such as web computing. Through a real-world example on the ATM Virtual Private Network server, we illustrate the feasibility and advantages of the proposed TMS method for synthesizing embedded real-time software.

Keywords: real-time embedded software, colored time Petri nets, quasi-static scheduling, code generation