2 ms·
Real-Time is a broad field and implemented in one of 3-ways a) On bare-metal, b) Using a RTOS (eg. FreeRTOS, QNX) c) On Linux/etc. As such you have to understan
by rramadass 4y ago
Real-Time is a broad field and implemented in one of 3-ways a) On bare-metal, b) Using a RTOS (eg. FreeRTOS, QNX) c) On Linux/etc. As such you have to understand what is actually involved when you say something is "real-time" (Hard/Soft). As a first approximation "real-time" can be said to be about minimizing latency (within accepted bounds) of service requests (ISRs, task functions etc). Thus if you do it via (a) above you get the best control but have to do everything, (b) gives you some framework support via a RTOS kernel and (c) is always "soft real-time" unless you break out of the kernel. The difficulty increases as you go from (a)->(b)->(c) since there are more intermediate layers and abstractions. But this is the best way to approach the study of the subject. With that in mind i can suggest the following books;
1) Real-Time Embedded Systems: Design Principles and Engineering Practices by Xiaocong Fan. - Good text book.
2) Introduction to Embedded Systems: Using Microcontrollers and the MSP430 by Manuel Jiminez et.al. - Very good book teaching you bare-metal MCU programming.
3) Hands-On RTOS with Microcontrollers: Building real-time embedded systems using FreeRTOS, STM32 MCUs, and SEGGER debug tools by Brian Amos - Great book showing the use of all tools/ecosystem needed for RTOS programming.
4) POSIX.4 Programmers Guide: Programming for the Real World by Bill Gallmeister. - The classic indispensable work on "real-time programming" for Unix-like systems.
- bdavis__ 4y agoThe #4 reference (gallmeister) is getting dated. The tarball of example source is still out there on the web. At the practical level, I would suggest the Redhat Realtime linux tuning guide. It covers practical ways to identify and remove latency and jitter from your system. My experience with the RH realtime kernel is 120 hz is usable. 60 hz can be very good. Of course, YMMV....
- rramadass 4y agoIMO, Gallmeister is still the best beginner's book since it explains the POSIX real-time profile apis succinctly. VxWorks/QNX/etc. all implement most of these apis thus giving the programmer a single view of the system which can be carried across most OSes. Another very good book i forgot to mention is: 5) Real-Time Systems and Programming Languages: Ada, Real-Time Java and C/Real-Time POSIX by Alan Burns and Andy Wellings. >At the practical level, I would suggest the Redhat Realtime linux tuning guide. It covers practical ways to identify and remove latency and jitter from your system. Agreed, but it deals with configuring the system rather than explicit coding. I listed it in another comment in this thread - https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux_for_real_time/9 https://access.redhat.com/documentation/en-us/red_hat_enterp...