Howto implement a periodic real-time task?

Udo A. Steinberg udo at
Tue Jul 21 12:02:28 CEST 2009

On Tue, 21 Jul 2009 11:03:38 +0200 Andre Puschmann (AP) wrote:

AP> I got a L4 real-time application that should run strictly periodic. In
AP> each cycle I have to communicate with at least two other L4 threads in
AP> different address spaces. The cycle period is in the order of 1000Hz to
AP> 5000Hz. As described in [1] I tried to use the CPU reservation server
AP> but the sample implementations did not work. Anyway, I figured out that
AP> even the CPU reservation server depends on the kernel timer and thus the
AP> granularity is 1ms (in PIT mode), which is too coarse for cycle periods
AP> larger then 1000Hz. Although I like the idea to use OS primitives to
AP> keep the application as portable as possible (ARM port is a goal), I
AP> thought about implementing the periodic execution with an extra timer
AP> decoupled from the scheduling timer which generates an IRQ at each hit.
AP> Any comment/suggestions/ideas about that? Any other experience with
AP> periodic real-time tasks on L4?

Configure your L4/Fiasco kernel to use the APIC in one-shot mode for
scheduling. Then, in combination with absolute timeouts, your granularity
can be as low as 1µs.

	- Udo
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <>

More information about the l4-hackers mailing list