ra8-firmware 0.1.0
Bare-metal firmware for the Renesas RA8 family (RA8D2 / RA8P1)
Loading...
Searching...
No Matches
ra8_wifi_backend.h
Go to the documentation of this file.
1
35
36#pragma once
37
38#ifdef __cplusplus
39extern "C" {
40#endif
41
42#include <stdint.h>
43
44#include "ra8_err.h"
45#include "ra8_wifi.h"
46
79 ra8_err_t (*open)(void* ctx);
80
87 ra8_err_t (*close)(void* ctx);
88
94 ra8_err_t (*radio_up)(void* ctx);
95
101 ra8_err_t (*radio_down)(void* ctx);
102
112 ra8_err_t (*join)(void* ctx, const char* ssid, const char* psk);
113
119 ra8_err_t (*leave)(void* ctx);
120
129 ra8_err_t (*service)(void* ctx, ra8_wifi_link_t* out_link);
130
137 ra8_err_t (*get_mac)(void* ctx, ra8_wifi_mac_t* out);
138
145 ra8_err_t (*get_ap)(void* ctx, ra8_wifi_ap_t* out);
146
161 void (*idle)(void* ctx, uint16_t ms);
162};
163
164#ifdef __cplusplus
165}
166#endif
Error Code Definitions for ra8-firmware.
ra8_err_codes_t ra8_err_t
Canonical error-return type used by every ra8-firmware API.
Definition ra8_err.h:546
A small, uniform Wi-Fi facade: init, connect, get an IP, disconnect.
struct ra8_wifi_ap ra8_wifi_ap_t
struct ra8_wifi_mac ra8_wifi_mac_t
ra8_wifi_link_t
The instantaneous association state a backend reports.
Definition ra8_wifi.h:182
One vtable per radio.
ra8_err_t(* open)(void *ctx)
Bring the radio's link up and prove it answers.
ra8_err_t(* radio_up)(void *ctx)
Start the radio in station mode.
ra8_err_t(* get_mac)(void *ctx, ra8_wifi_mac_t *out)
Read the station's own MAC address.
ra8_err_t(* get_ap)(void *ctx, ra8_wifi_ap_t *out)
Read what the radio knows about the associated AP.
ra8_err_t(* join)(void *ctx, const char *ssid, const char *psk)
Ask the station to associate with a network.
ra8_err_t(* close)(void *ctx)
Release the link the backend opened.
ra8_err_t(* service)(void *ctx, ra8_wifi_link_t *out_link)
Service the link once and report the association state.
void(* idle)(void *ctx, uint16_t ms)
Idle for ms milliseconds, pacing a bounded wait.
ra8_err_t(* radio_down)(void *ctx)
Stop the radio and release its resources.
ra8_err_t(* leave)(void *ctx)
Disassociate the station from its network.