The QP-nano 5.4.0 release changes the basic philosophy of packaging and distributing the QP-nano framework by combining the "QP-nano Baseline Code" with all currently available "QP-nano Development Kits" (QDK-nano). This is done to eliminate any potential mistakes in downloading and installing separate pieces of code.
This release also changes the active object class hierarchy so that QMActive is now more fundamental and is the base class for QActive. (Previously QMActive was a subclass of QActive). The newly added documentation section about QP-nano Design shows the current class hierarchy.
NOTE: Because the types QMActive and QActive are equivalent in QP-nano, this change has minimal impact on the applications, but it is now more correct to use QMActive as the base class for all "opaque" active object pointers.
Additionally, this release alignes the QP-nano framework better with the rest of the QP framework family (QP/C and QP/C++), so that fewer changes are needed to move applications between QP-nano and QP/C.
Finally, this release adds periodic time events (timers) to QP-nano. The feature is demonstrated by many provided examples (e.g., "Blinky", "Fly 'n' Shoot" game, PELICAN crossing).
The aforementioned changes have also the following ripple effects:
The structure of the QP-nano ports has been modified to match QP/C and to avoid repetitions. The QP-nano application no longer need to provide and #include the complete port qpn_port.h header file, which is now deprecated. Insted QP-nano application code needs to #include the qpn.h (QP-nano API) header file, which also now contains the QP-nano backwards-compatibility layer.
The application is now only responsible for providing the qpn_conf.h file to set up the basic configuration for QP-nano. Examples of the qpn_config.h configurations are provided in all supplied QP-nano examples.
The actual port (e.g., the interrupt disabling policy for tasks and interrupts, interrupt entry/exit code, etc.) is included from the Ports folder. This Ports folder has been reorganized to contain all currently available QP-nano ports. The ports are organized into two categories:
native QP-nano ports ("bare-metal") and ports to big operating systems (Windows and Linux).(NOTE: the ports are now documented in the this QP-nano Reference Manual. Each port sub-directory contains a README link to the corresponding page in the online documentation)
Expanded the QP-nano time events (timers) with the ability to fire periodically. The feature is controlled by the preprocessor switch QF_TIMEEVT_PERIODIC. When this macro is defined (in the qpn_config.h header file), the signature of the QActive_armX() function contains one more interval parameter. The interval parameter allows you to specify the interval of the periodic timeout. If the interval is zero, the time event is one-shot.
It is no longer necessary to define the QPN environment variable to build the QP-nano examples. All directories and files referenced by example projects are relative to the project folder. This change reflects the fact that most development tools add source files to the project using relative paths.
The QP-nano Examples folder has been reorganized to reduce the repetitions and contains all currently available QP-nano examples. The folder includes four categories of examples: native QP-nano examples ("bare-metal") and examples for big operating systems (Windows and Linux). The examples folder has been expanded to contain all currently available QP-nano examples, many of them are new in this release. (NOTE: the currently available examples are now documented in the
QP-nano Reference Manual. Each example sub-directory contains a README link to the corresponding page in the online documentation)
A new 3rd_party folder created to contain the Third-Party code used in the QP-nano ports and examples, such as MCU register files, low-level startup code, device drivers, etc. The 3rd_party folder avoids the need to repeat such code in every project. Also, the separation of the Third-Party components helps to clearly indicate code that comes from various sources, and to which Quantum Leaps, LLC expressly makes no claims of ownership. The Third-Party software components included in this "3rd_party" folder are licensed under a variety of different licensing terms that are defined by the respective owners of this software and are spelled out in the README.txt or LICENSE.txt files included in the respective sub-folders.
This release also comes with the much expanded online QP-nano Reference Manual, which is cross-linked with the ports and examples.
Changes in detail:
Renamed the "Vanilla" scheduler to the QV-nano cooperative kernel for symmetry with the QK-nano preemptive kernel. Renamed QF_onIdle() callback to QV_onIdle().
Removed class QFsm (which is now deprecated). Legacy state machines coded in the "QFsm-style" will continue to work, but will use the QHsm implementation internally. There is no longer any efficiency advantage in using the "QFsm-style" state machines.
Updated ARM Cortex-M examples and provided new examples for NXP mbed-LPC1768, and STM32 NUCLEO-L053R8, and NUCLEO-L152RE boards. All examples now use the latest CMSIS (V4.3.0). All ARM Cortex-M exampels are provided for the ARM-KEIL, GNU-ARM, and IAR-ARM toolsets.
Added the native port and examples to the classic ARM7/9 with AT91SAM7S-EK board and the IAR-ARM toolset.
Added the native port and examples to the AVR (AVRmega) with GNU-AVR and IAR-AVR toolsets. The examples are provided for the Arduino-UNO board.
Added the native port and examples to MSP430 with TI CCS-430 and IAR-430 toolsets. The examples are provided for the MSP430 LauchPad boards (the MSP-EXP430G2 and MSP-EXP430F5529LP for the "classic" MSP430 and "extened" MSP430X, respectively).
Updated port to Win32-QV (Windows with cooperative "Vanilla" scheduler, previously known as Win32-1T). Modified the port to apply a "fudge factor" in over-sizing QP-nano event queues and event pools, to minimize the risk of overflowing queues/pools due to non-deterministic
Windows behavior.
Renamed the POSIX port to POSIX-QV (POSIX with cooperative "Vanilla" scheduler). Modified the port to apply a "fudge factor" in over-sizing QP-nano event queues and event pools, to minimize the risk of overflowing queues/pools due to non-deterministic behavior under POSIX.