26#define WIFI_SAVED_MAX 6
81bool wifi_saved_add(
const char *ssid,
const char *password, uint8_t security);
bool wifi_saved_add(const char *ssid, const char *password, uint8_t security)
Add or update a network in saved list. If SSID already exists, updates in-place. If not,...
bool wifi_saved_store(int index, const wifi_saved_entry_t *entry)
Store a network entry to OPTIGA slot.
bool wifi_saved_probe_ready(void)
อาจเป็น true ทันทีหลัง probe_start() — ต้องรองรับเส้นทางลัดที่มาจากผลที่แคชไว้
int wifi_saved_find(const char *ssid)
Find a saved network by SSID.
bool wifi_saved_probe_start(void)
ส่ง probe ตรวจการมีอยู่ของ OPTIGA; ต้องเรียงลำดับ start → ready → finish อย่างเคร่งครัด
bool wifi_saved_read_ready(void)
ยังไม่พร้อมหมายถึงให้ลองใหม่ใน tick ถัดไป
bool wifi_saved_read_result(wifi_saved_entry_t *out)
เติมข้อมูลลงในรายการที่ผู้เรียกเป็นเจ้าของ; false หมายถึงไม่มีข้อมูลใน slot นั้น
int wifi_saved_count(void)
Count number of valid saved networks.
void wifi_saved_probe_finish(void)
เรียกเพียงครั้งเดียวต่อหนึ่ง probe และเฉพาะหลัง probe_ready() เท่านั้น; เป็นตัวตั้งสถานะ OPTIGA / RAM...
int wifi_saved_load_all(wifi_saved_entry_t *entries)
Load all saved networks into an array.
bool wifi_saved_load(int index, wifi_saved_entry_t *out)
Load a saved network from OPTIGA slot.
bool wifi_saved_erase(int index)
Erase a saved network from OPTIGA slot.
bool wifi_saved_read_start(int index)
มีการอ่าน slot ค้างอยู่ได้ครั้งละหนึ่งรายการเท่านั้น; การคืนค่า false หมายถึงข้าม slot นั้นไป
wifi_saved_entry_t
Definition wifi_saved.h:36
struct __attribute__((packed))
Definition wifi_saved.h:29