K-FSW v1.2.1-59-gcaca356
KFSW: modular flight software on Zephyr, for small satellites
Loading...
Searching...
No Matches

Public Headers

file  uart.h
 

Data Structures

struct  kfsw_uart_info
 
struct  kfsw_uart_test_result
 
struct  kfsw_uart_codec
 

Types

typedef bool(* kfsw_uart_visitor_t) (const struct kfsw_uart_info *uart_info, void *context)
 

Functions

void kfsw_uart_get_info (struct kfsw_uart_info *info)
 
void kfsw_uart_visit (kfsw_uart_visitor_t visitor, void *context)
 
int kfsw_uart_test_peer (uint16_t peer, uint32_t timeout_ms, struct kfsw_uart_test_result *test_result)
 
int kfsw_uart_codec_register (const char *interface_name, const struct kfsw_uart_codec *codec)
 
int kfsw_uart_codec_control (uint16_t peer, const uint8_t *data, size_t size)
 

Description

UART/KISS configuration, counters and peer tests.

kfsw_uart_visit() reports every configured interface and its counters; kfsw_uart_test_peer() verifies and reports the UART selected for a node.

Function Documentation

◆ kfsw_uart_codec_control()

int kfsw_uart_codec_control ( uint16_t  peer,
const uint8_t *  data,
size_t  size 
)

#include <uart_codec.h>

Send a codec control payload directly on its bound interface.

Thread context only.

◆ kfsw_uart_codec_register()

int kfsw_uart_codec_register ( const char *  interface_name,
const struct kfsw_uart_codec *  codec 
)

#include <uart_codec.h>

Register a static codec before CSP initialization.

One registration only.

◆ kfsw_uart_get_info()

void kfsw_uart_get_info ( struct kfsw_uart_info *  info)

#include <uart.h>

Read the first CSP UART configuration for legacy one-interface callers.

◆ kfsw_uart_test_peer()

int kfsw_uart_test_peer ( uint16_t  peer,
uint32_t  timeout_ms,
struct kfsw_uart_test_result *  test_result 
)

#include <uart.h>

Ping a peer and report the KISS/UART interface selected by the CSP route.

Returns CSP_ERR_NOTSUP when that route is not a UART, or the peer is this node and the ping would never leave it.

◆ kfsw_uart_visit()

void kfsw_uart_visit ( kfsw_uart_visitor_t  visitor,
void *  context 
)

#include <uart.h>

Visit every independently configured CSP KISS/UART interface.