KNX IoT add-on architecture
This page describes what the KNX IoT add-on provides and how it integrates the KNX IoT Point API stack into the nRF Connect SDK. For the protocol concepts referenced here, see the Introduction.
Add-on components
The KNX IoT add-on brings the KNX IoT Point API to Nordic Semiconductor devices running the nRF Connect SDK. It consists of the following parts:
The third-party KNX IoT Point API stack (the upstream open-source stack), pulled in as a west module and built for the nRF Connect SDK. See the KNX IoT Point API Stack repository.
A small integration library under
subsys/knx/that adapts the stack to the nRF Connect SDK, drives its event loop, and provides shared board support.Samples that demonstrate basic KNX IoT functional blocks over Thread (see the KNX-IoT samples).
This documentation.
The KNX IoT add-on is enabled with the CONFIG_KNX_IOT_ADD_ON Kconfig option, which brings in the stack together with the integration library and selects the required dependencies (for example, the PSA Crypto features used by KNX IoT security).
See Shared configurations in KNX IoT add-on for the configuration options.
Component overview
The following diagram shows how a KNX IoT add-on application is layered on top of the KNX IoT Point API stack, the OpenThread stack, and the nRF Connect SDK.
Integration library
The integration library under subsys/knx/ allows for easy integration of the KNX stack to user applications.
Its main source files are:
knx_app.c,knx_stack.c- Initialize and run the KNX IoT stack, including the event loop.knx_resources.c- Register the application’s KNX resources (functional blocks and datapoints).knx_transport.c- Adapt the stack to the underlying IPv6/Thread transport.knx_board.c- Shared board support (status LED, button dispatch), built whenCONFIG_DK_LIBRARYis enabled.knx_presets.c- The hardcoded commissioning mechanism, built whenCONFIG_KNX_HARDCODED_COMMISSIONINGis enabled (see Commissioning).
The stack runs its event loop on a dedicated worker thread whose scheduling priority is set with the CONFIG_KNX_THREAD_PRIORITY Kconfig option.
Relationship to the upstream stack
The KNX IoT functionality itself comes from the upstream Point API stack, and it is integrated by the KNX IoT add-on.
The KNX IoT add-on disables the stack’s bundled demo applications and replaces them with its own device-agnostic application layer in subsys/knx/.
For upstream documentation, the protocol specifications, and schemas, see the KNX IoT documentation and KNX IoT downloads and schemas.
For the current feature coverage and limitations, see Software maturity and Known issues.