NHAL Interface v0.5.0
Hardware Abstraction Layer Interface for Embedded Systems
Loading...
Searching...
No Matches
nhal_uart_async.h
Go to the documentation of this file.
1
15#ifndef NHAL_UART_ASYNC_H
16#define NHAL_UART_ASYNC_H
17
18#include <stddef.h>
19#include <stdint.h>
20
21#include "nhal_common.h"
22#include "nhal_uart_types.h"
23
24#ifdef __cplusplus
25extern "C" {
26#endif
27
28#if defined(NHAL_UART_ASYNC_SUPPORT)
29
37 struct nhal_uart_context * ctx,
38 const struct nhal_async_config * async_cfg
39);
40
47 struct nhal_uart_context * ctx
48);
49
57 struct nhal_uart_context *ctx,
59);
60
67 struct nhal_uart_context *ctx
68);
69
76 struct nhal_uart_context *ctx
77);
78
88 struct nhal_uart_context * ctx,
89 const uint8_t *data, size_t len
90);
91
101 struct nhal_uart_context * ctx,
102 uint8_t *data, size_t len
103);
104
105#endif /* NHAL_UART_ASYNC_SUPPORT */
106
107#ifdef __cplusplus
108}
109#endif
110
111#endif /* NHAL_UART_ASYNC_H */
void(* nhal_async_complete_cb_t)(void *context)
Definition nhal_common.h:56
nhal_result_t
Unified HAL result type for all peripheral operations.
Definition nhal_common.h:22
nhal_async_status_t
Definition nhal_common.h:8
nhal_result_t nhal_uart_disable_async_callback(struct nhal_uart_context *ctx)
Disable async completion callback.
nhal_result_t nhal_uart_write_async(struct nhal_uart_context *ctx, const uint8_t *data, size_t len)
Write data asynchronously.
nhal_result_t nhal_uart_set_async_callback(struct nhal_uart_context *ctx, nhal_async_complete_cb_t callback)
Set callback for async operation completion.
nhal_result_t nhal_uart_init_async(struct nhal_uart_context *ctx, const struct nhal_async_config *async_cfg)
Initialize UART context for async mode.
nhal_result_t nhal_uart_deinit_async(struct nhal_uart_context *ctx)
Deinitialize UART async mode.
nhal_result_t nhal_uart_read_async(struct nhal_uart_context *ctx, uint8_t *data, size_t len)
Read data asynchronously.
nhal_async_status_t nhal_uart_get_async_status(struct nhal_uart_context *ctx)
Get current async operation status.
Defines common data types, enumerations, and structures for UART HAL operations.
Base UART context - always present, minimal footprint.