inherently support and automatically enforce the following best practices of concurrent programming:
Keep all of the task's data local, bound to the task itself and hidden from the rest of the system.
Communicate among tasks asynchronously via intermediary event objects. Using asynchronous event posting keeps the tasks running truly independently without blocking on each other.
Tasks should spend their lifetime responding to incoming events, so their mainline should consist of an event loop.
Active objects dramatically improve your ability to reason about the concurrent software. In contrast, using raw RTOS tasks directly is trouble for a number of reasons, particularly because raw tasks let you do anything and offer you no help or automation for the best practices. As with all good patterns, active objects raise the level of abstraction above the naked threads and let you express your intent more directly thus improving your productivity. Active objects cannot operate in a vacuum and require a software infrastructure that provides, at a minimum: an execution thread for each active object, queuing of events, and event-based timing services. In the resource-constrained embedded systems, the biggest concern has always been about scalability and efficiency of such frameworks, especially that the frameworks accompanying various modeling tools have traditionally been built on top of a conventional RTOS, which adds memory footprint and CPU overhead to the final solution. The QP frameworks have been designed for efficiency and minimal footprint from the ground up and do not need an RTOS in the stand-alone configuration. In fact, when compared to conventional RTOSes, QP frameworks provide smaller footprint especially in RAM, but also in ROM. This is possible, because active objects don't need toblock, so most blocking mechanisms of a conventional RTOS are not needed. All these characteristics make event-driven active objects a perfect fit for single-chip microcontrollers. Not only do you get the productivity boost by working at a higher level of abstraction than raw RTOS tasks, but you get it at a lower resource utilization and better power efficiency, because event-driven systems use the CPU only when processing events and otherwise can put the chip in a low-power sleep mode.
QP architecture and components
QP consists of a universal UML-compliant event processor, a portable, event-driven, real-time framework, a tiny run-to-completion kernel, and software tracing system. QEP is a universal UML-compliant event processor that enables direct coding of UML state machines in highly maintainable C or C++, in which every state machine element is mapped to code precisely, unambiguously, and exactly once. QEP fully supports hierarchical state nesting, which enables reusing behavior across many states instead of repeating the same actions and transitions over and over again. QF is a highly portable, event-driven, real-time application framework for concurrent execution of state machines specifically designed for real-time embedded systems. QK is a tiny preemptive non-blocking run-to-completion kernel designed specifically for executing state machines in a run-to-completion fashion. QS is a software tracing system that enables live monitoring of event-driven QP applications with minimal target system resources and without stopping or significantly slowing down the code.
Supported processors
All types of QP frameworks can be easily adapted to various microprocessor architectures and compilers. Adapting the QP software is called porting and all QP frameworks have been designed from ground up to make the porting easy. Currently, bare-metal QP ports exist for the following processor architectures:
The QP/C and QP/C++ frameworks can also work with the traditional operating systems and RTOSes. Currently, QP ports exist for the following OSes/RTOSes:
All QP framework types are dual-licensed under the open sourceGPLv2 and a traditional, closed-source license. Users who want to distribute QP can retain the proprietary status of their code for a fee. Several types of commercial, royalty-free, closed-source licenses are available.