Is Luos for me? 🤔

MCU with Luos

Compatible MCUs

Luos can manage any microcontrollers as long as they have a LuosHAL. If your microcontroller is not supported yet, you can create your own LuosHAL version or contact us:

Check the list of the MCU families Luos covers:Hardware Abstraction Layers for MCU Families ↗,

Default Configuration

Luos libraries are made to run on MCU and use hardware peripheral of the MCU to complete communication between services. In order to configure this low-level part, Luos provides for many MCU families a default configuration that can lead to plug-and-play the Luos library with the chosen MCU family. The peripheral configuration is described in files luos_hal_config.h in the repository Luos HAL ↗, and can be redefined in the node_config.h file to fit with your design.

Luos HAL configuration

To match the pinout and functionality with your design, you can create or use the file node_config.h (see Luos example) As you can see on the default configuration, defined in luos_hal_config.h, you are able to define in the file node_config.h, in the section "LUOS HAL LIBRARY DEFINITION", parameters like pinout, usart, timer, etc.

In this way, you will be able to change the default hardware configuration and use it by calling it in the preprossessor variable section of your IDE, so that it is taken into consideration for your project.

Note: Every example provided by Luos has a node_config.h file, which is included by the PlatformIO project's initialization file, called platformio.ini.

Example of PTPA redefinition:

In luos_hal_config.h this is defined as followed:

#ifndef PTPA_PIN
#define PTPA_PIN                    GPIO_PIN_8
#endif

In node_config.h this should be redefined as followed:

#define PTPA_PIN                    GPIO_PIN_11

There are many possible configurations that you can change, but not all of them may be necessary for your design:

Pinout

FunctionDescriptionComments
PORT_CLOCK_ENABLEActivates clock for GPIODepends on port
RX_EN_PIN/TX_EN_PINChooses pinout to activate Rx/Tx commsNecessary for special comms
COM_TX_PIN/COM_RX_PINChooses pinout for Rx/Tx commsAdapts to the chosen serial bus
PTPX_PIN/PTPX_IRQ/PINOUT_IRQHANDLERChooses pinout, IRQ and callback for the PTP lineNecessary for topology detection

Communication

FunctionDescriptionComments
LUOS_COM_CLOCK_ENABLEActivates clock for serialDepends on serial bus
LUOS_COM/LUOS_COM_IRQ/LUOS_COM_IRQHANDLERChooses serial bus, IRQ and callbackAdapts to the serial bus chosen
LUOS_DMA_CLOCK_ENABLEActivates clock for DMANecessary for for Tx
LUOS_DMA_CHANNELChooses ChannelSend Tx

Timer

FunctionDescriptionComments
LUOS_TIMER_CLOCK_ENABLEActivates clock for TimeoutNecessary for Timeout
LUOS_TIMER/LUOS_TIMER_IRQ/LUOS_TIMER_IRQHANDLERChooses Timer, IRQ and callbackNecessary for Timeout

Flash

FunctionDescriptionComments
PAGE_SIZE/ADRESS_LAST_PAGEDefines space in flash for aliasNecessary to rename service alias