Summary

This chapter explores using Linux as an event timer with 1ms resolution. Linux offers several mechanisms for timing, and the do_gettimeofday function with microsecond resolution works best for the three Project Trailblazer target board processors. Whereas determining maximum interrupt latency is difficult, measuring average interrupt latency is relatively easy. Using the interrupt latency device drivers and an oscilloscope, the engineers found the average interrupt latency for the MZ104, the MediaEngine, and the RPX-CLLF to be 50μs, 10μs, and 35μs, respectively. These impressive numbers alleviated the need for the engineers to explore real-time Linux solutions.

The racetimer_x86 device driver implements a split interrupt driver and a ...

Get Embedded Linux®: Hardware, Software, and Interfacing now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.