Skip to main content
Version: 2.7.0

Luos Engine APIs

Core API

Main Library API

FunctionDescriptionParametersreturn
void Luos_Init(void)The main initialization of Luos Engine
Library need to be call before all
service declaration
FunctionDescriptionParametersreturn
void Luos_Loop(void)The main Loop of Luos Engine Library
manage message mecanism

Package management API

FunctionDescriptionParametersreturn
void Luos_AddPackage(Register a Package that will be run
void (*Init)(void),by Luos_Run APIaddress to package init function
void (*Loop)(void))manage message mecanismaddress to package loop function
FunctionDescriptionParametersreturn
void Luos_Run(void)Run Luos Init/Loop and all package
Init/Loop registered

Topology API

FunctionDescriptionParametersreturn
void Luos_Detect(Reset Network and Start
service_t *service)Topology detectionPointer to service asking detection
FunctionDescriptionParametersreturn
bool Luos_IsNodeDetected(void)Indicate end of network detectionstatus of the node for the detection
FunctionDescriptionParametersreturn
void Luos_SetExternId()set id of a service trough the network
service_t *service,Pointer to the service
target_mode_t target_mode,way to send to target
uint16_t target,Target
uint16_t newid)New value ID

Service API

FunctionDescriptionParametersreturn
service_t *Luos_CreateServiceService Creation APIPointer service just created
SERVICE_CB service_cb,Message handler for the service
uint8_t type,Type of service you created
const char *alias,Alias of the service
revision_t revision)Revision of your service (optionnal)
FunctionDescriptionParametersreturn
void Luos_ServicesClear(void)clear all service for the node

Message API

FunctionDescriptionParametersreturn
error_return_t Luos_SendMsg(Send a Luos messageSUCCEDED or FAILED
service_t *service,Pointer to the service
msg_t *msg)Pointer to the msg
FunctionDescriptionParametersreturn
error_return_t Luos_ReadMsg(Read Last Luos message receivedSUCCEDED or FAILED
service_t *service,(Use in Polling Mode)Pointer to the service
**returned_msg)Pointer to adress msg in buffer
FunctionDescriptionParametersreturn
error_return_t Luos_ReadFromService(Read Last Luos message receivedSUCCEDED or FAILED
service_t *service,for a service(Use in Polling Mode)Pointer to the service
int16_t id,ID of service
**returned_msg)Pointer to adress msg in buffer
FunctionDescriptionParametersreturn
void Luos_SendData(Send the remaining data in case of
service_t *service,long messagesPointer to the service
void *bin_data,Pointer to data
uint16_t size)size of data
FunctionDescriptionParametersreturn
int Luos_ReceiveData(Receive the remaining data in caseNumber of data left to receive for msg
service_t *service,of long messagesPointer to the service
msg_t *msg,Pointer to the msg
void *bin_data)Pointer to data
FunctionDescriptionParametersreturn
void Luos_SendStreaming(Send data stored in a
service_t *service,streaming channelPointer to the service
msg_t *msg,Pointer to the msg
streaming_channel_t *stream)Pointer to streaming channel
FunctionDescriptionParametersreturn
void Luos_SendStreamingSize(Send a size of data stored in
service_t *service,streaming channelPointer to the service
msg_t *msg,Pointer to the msg
streaming_channel_t *streamPointer to streaming channel
uint32_t max_size)Pointer to streaming channel
FunctionDescriptionParametersreturn
error_return_t Luos_ReceiveStreaming(Receive data from a streaming channel
service_t *service,Pointer to the service
msg_t *msg,Pointer to the msg
streaming_channel_t *streamPointer to streaming channel
FunctionDescriptionParametersreturn
error_return_t Luos_TxComplete(void)Check Tx buffer emptySUCCEDED or FAILED
FunctionDescriptionParametersreturn
uint16_t Luos_NbrAvailableMsg(void)Number of received message in bufferNumber of message

Other API

FunctionDescriptionParametersreturn
uint32_t Luos_GetSystick(void)Get a tick at msTick number
FunctionDescriptionParametersreturn
void Luos_ResetStatistic(void)Reset node statistic
FunctionDescriptionParametersreturn
void Luos_SetFilterState(Filter to message for a service
uint8_t state,state of filter (on/off)
service_t *service)Pointer to the service

Routing Table research API

FunctionDescriptionParametersreturn
error_return_t RTFilter_InitCheck(Init result tab routing tableSUCCEDED or FAILED
search_result_t *result)Pointer to result table
FunctionDescriptionParametersreturn
search_result_t *RTFilter_Reset(Reset the results tableresult of filter routing table
search_result_t *result)Pointer to result table
FunctionDescriptionParametersreturn
search_result_t *RTFilter_ID(Find a the service of a specific idresult of filter routing table
search_result_t *resultPointer to result table
uint16_t id)ID to filter
FunctionDescriptionParametersreturn
search_result_t *RTFilter_Type(Find the services of a specific typeresult of filter routing table
search_result_t *resultPointer to result table
luos_type_t type)type to filter
FunctionDescriptionParametersreturn
search_result_t *RTFilter_Node(Find the services of a specific Noderesult of filter routing table
search_result_t *resultPointer to result table
uint16_t node_id)Node id to filter
FunctionDescriptionParametersreturn
search_result_t *RTFilter_Alias(Find the services of a specific aliasresult of filter routing table
search_result_t *resultPointer to result table
char *alias)Alias to filter
FunctionDescriptionParametersreturn
search_result_t *RTFilter_Service(Find the services of a specific aliasresult of filter routing table
search_result_t *resultPointer to result table
service_t *service)Service to filter

Streaming API

FunctionDescriptionParametersreturn
streaming_channel_t Stream_CreateStreamingChannel(Create a streaming ChannelPointer to stream channel created
const void *ring_buffer,to send/receive dataPointer to ring buffer
uint16_t ring_buffer_size,Size of ring buffer
uint8_t data_size)size of data to stream(8, 16, 32 bits)
FunctionDescriptionParametersreturn
void Stream_ResetStreamingChannel(Reset a streaming Channel
streaming_channel_t *stream)Pointer to stream channel
FunctionDescriptionParametersreturn
uint16_t Stream_PutSample(Put some sample in streaming channelnumber available samples in streaming
streaming_channel_t *streamPointer to stream channel
const void *data,Pointer to data to send
uint16_t size)Size to send
FunctionDescriptionParametersreturn
uint16_t Stream_GetSample(Get some sample in streaming channelnumber available samples in streaming
streaming_channel_t *streamPointer to stream channel
void *data,Pointer to data to send
uint16_t size)Size to send
FunctionDescriptionParametersreturn
uint16_t Stream_GetAvailableSampleNB(Get sample number in streaming channelnumber available samples in streaming
streaming_channel_t *stream)Pointer to stream channel
FunctionDescriptionParametersreturn
uint16_t Stream_GetAvailableSampleNBUntilEndBuffer(Get sample number until the end ofNumber data until end circular buffer
streaming_channel_t *stream)streaming channelPointer to result table
FunctionDescriptionParametersreturn
uint16_t Stream_AddAvailableSampleNB(Add number of available sampleNumber data until end circular buffer
streaming_channel_t *stream,Pointer to result table
uint16_t size)Size of data
FunctionDescriptionParametersreturn
uint16_t Stream_RmvAvailableSampleNB(remove number of available sampleNumber data until end circular buffer
streaming_channel_t *stream,Pointer to result table
uint16_t size)Size of data