SINGLE-STACK REAL-TIME OPERATING SYSTEM FOR EMBEDDED SYSTEMS
First Claim
1. A real time operating system (RTOS) for a computer processor performing a first plurality of tasks including a first task and a second task, the RTOS comprising:
- a subsystem providing a plurality of task priorities such that not all of the first plurality of tasks run at the same priority, wherein the first plurality of tasks share and use only a single stack;
a task scheduler that, when invoked, switches control to a highest-priority one of the first plurality of tasks;
a continuations library subsystem that automatically manages a plurality of continuation points including a first continuation point;
a yield function that sets the first continuation point in the first task and yields control to the task scheduler, whereupon the task scheduler switches control to the second task and wherein at a later time the task scheduler switches control back to the first task at the first continuation point; and
a nested blocking function call subsystem, that invokes a second blocking function in the second task from within a first blocking function in the second task and yields control to the task scheduler.
2 Assignments
0 Petitions
Accused Products
Abstract
A real time operating system (RTOS) for embedded controllers having limited memory includes a continuations library, a wide range of macros that hide continuation point management, nested blocking functions, and a communications stack. The RTOS executes at least a first and second task and uses a plurality of task priorities. The tasks share only a single stack. The task scheduler switches control to the highest-priority task. The continuations library provides macros to automatically manage the continuation points. The yield function sets a first continuation point in the first task and yields control to the task scheduler, whereupon the task scheduler switches to the second task and wherein at a later time the task scheduler switches control back to the first task at the first continuation point. The nested blocking function invokes other blocking functions from within its body and yields control to the task scheduler.
24 Citations
20 Claims
-
1. A real time operating system (RTOS) for a computer processor performing a first plurality of tasks including a first task and a second task, the RTOS comprising:
-
a subsystem providing a plurality of task priorities such that not all of the first plurality of tasks run at the same priority, wherein the first plurality of tasks share and use only a single stack; a task scheduler that, when invoked, switches control to a highest-priority one of the first plurality of tasks; a continuations library subsystem that automatically manages a plurality of continuation points including a first continuation point; a yield function that sets the first continuation point in the first task and yields control to the task scheduler, whereupon the task scheduler switches control to the second task and wherein at a later time the task scheduler switches control back to the first task at the first continuation point; and a nested blocking function call subsystem, that invokes a second blocking function in the second task from within a first blocking function in the second task and yields control to the task scheduler. - View Dependent Claims (2, 3, 4, 5)
-
-
6. A computerized method of real time operating system (RTOS) operation of a computer processor, the method comprising:
-
performing, in the computer processor, a first plurality of tasks including a first task and a second task, wherein not all of the first plurality of tasks run at the same priority, wherein the first plurality of tasks share and use only a single stack; providing a single stack; using and sharing the single stack by all of the first plurality of tasks; automatically managing a plurality of continuation points, wherein the plurality of continuation points includes a first continuation point and a second continuation point; creating the first continuation point in the first task and yielding control to a task scheduler; selectively switching control to a highest-priority one of the first plurality of tasks using the task scheduler, wherein the second task is the highest-priority one of the first plurality of tasks; switching control back to the first task at the first continuation point at a later time; and executing a first blocking function within the first task such that the task scheduler switches to the second task and executing a second blocking function in the second task before continuing the first task after the first blocking function has executed. - View Dependent Claims (7, 8, 9, 10)
-
-
11. A computer-readable medium having instructions embedded thereon, wherein the instructions, when performed on a computer processor, execute a method of real time operating system (RTOS) operation, the method comprising:
-
performing, in the computer processor, a first plurality of tasks including a first task and a second task, wherein not all of the first plurality of tasks run at the same priority, wherein the first plurality of tasks share and use only a single stack; providing a single stack; using and sharing the single stack by all of the first plurality of tasks; automatically managing a plurality of continuation points, wherein the plurality of continuation points includes a first continuation point and a second continuation point; creating the first continuation point in the first task and yielding control to a task scheduler; selectively switching control to a highest-priority one of the first plurality of tasks using the task scheduler, wherein the second task is the highest-priority one of the first plurality of tasks; switching control back to the first task at the first continuation point at a later time; and executing a first blocking function within the first task such that the task scheduler switches to the second task and executing a second blocking function in the second task before continuing the first task after the first blocking function has executed. - View Dependent Claims (12, 13, 14, 15)
-
-
16. A computing apparatus having a real time operating system (RTOS), the apparatus comprising:
-
means for performing, in the computing apparatus, a first plurality of tasks including a first task and a second task, wherein not all of the first plurality of tasks run at the same priority, wherein the first plurality of tasks share and use only a single stack; a task scheduler; a single stack; means for using and sharing the single stack by all of the first plurality of tasks; means for automatically managing a plurality of continuation points, wherein the plurality of continuation points includes a first continuation point and a second continuation point; means for creating the first continuation point in the first task and for yielding control to the task scheduler; means for selectively switching control to a highest-priority one of the first plurality of tasks using the task scheduler, wherein the second task is the highest-priority one of the first plurality of tasks; means for switching control back to the first task at the first continuation point at a later time; and means for executing a first blocking function within the first task such that the task scheduler switches to the second task and executing a second blocking function in the second task before the first task is continued after the first blocking function has executed. - View Dependent Claims (17, 18, 19, 20)
-
Specification