import { n as ServiceHandle, t as ServiceClientOptions } from "../service-rpc-BugpSF7V.mjs"; import { a as WifiScanParams, i as WifiScanApInfo, n as WifiGeneralAction, o as WifiSoftApParams, r as WifiGeneralState, t as WifiConnectApInfo } from "../wifi-types-CG1LJvWZ.mjs"; //#region src/wifi/wifi-client.d.ts /** Registered name (`helper::Wifi::get_name()`). */ declare const WIFI_SERVICE_NAME = "Wifi"; /** RPC function names (`helper::Wifi::FunctionId`). */ declare const WIFI_FUNCTIONS: { readonly TriggerGeneralAction: "TriggerGeneralAction"; readonly GetGeneralState: "GetGeneralState"; readonly SetConnectAp: "SetConnectAp"; readonly GetConnectAp: "GetConnectAp"; readonly GetConnectedAps: "GetConnectedAps"; readonly SetScanParams: "SetScanParams"; readonly TriggerScanStart: "TriggerScanStart"; readonly TriggerScanStop: "TriggerScanStop"; readonly SetSoftApParams: "SetSoftApParams"; readonly GetSoftApParams: "GetSoftApParams"; readonly TriggerSoftApStart: "TriggerSoftApStart"; readonly TriggerSoftApStop: "TriggerSoftApStop"; readonly TriggerSoftApProvisionStart: "TriggerSoftApProvisionStart"; readonly TriggerSoftApProvisionStop: "TriggerSoftApProvisionStop"; readonly RemoveConnectedAp: "RemoveConnectedAp"; readonly LoadData: "LoadData"; readonly ResetData: "ResetData"; }; type WifiClientOptions = ServiceClientOptions; declare function isWifiAvailable(options?: WifiClientOptions): boolean; declare function openWifi(options?: WifiClientOptions): ServiceHandle; declare function closeWifi(handle: ServiceHandle, options?: WifiClientOptions): void; declare function triggerGeneralAction(handle: ServiceHandle, action: WifiGeneralAction, options?: WifiClientOptions): void; declare function getGeneralState(handle: ServiceHandle, options?: WifiClientOptions): WifiGeneralState; declare function setConnectAp(handle: ServiceHandle, ssid: string, password?: string, options?: WifiClientOptions): void; declare function getConnectAp(handle: ServiceHandle, options?: WifiClientOptions): WifiConnectApInfo; declare function getConnectedAps(handle: ServiceHandle, options?: WifiClientOptions): WifiConnectApInfo[]; declare function setScanParams(handle: ServiceHandle, params: WifiScanParams, options?: WifiClientOptions): void; declare function triggerScanStart(handle: ServiceHandle, options?: WifiClientOptions): void; declare function triggerScanStop(handle: ServiceHandle, options?: WifiClientOptions): void; declare function setSoftApParams(handle: ServiceHandle, params: WifiSoftApParams, options?: WifiClientOptions): void; declare function getSoftApParams(handle: ServiceHandle, options?: WifiClientOptions): WifiSoftApParams; declare function triggerSoftApStart(handle: ServiceHandle, options?: WifiClientOptions): void; declare function triggerSoftApStop(handle: ServiceHandle, options?: WifiClientOptions): void; declare function triggerSoftApProvisionStart(handle: ServiceHandle, options?: WifiClientOptions): void; declare function triggerSoftApProvisionStop(handle: ServiceHandle, options?: WifiClientOptions): void; declare function resetWifiData(handle: ServiceHandle, options?: WifiClientOptions): void; //#endregion //#region src/wifi/wifi.d.ts type WifiModuleOptions = WifiClientOptions; /** * Inject a mock RPC host and reset the cached service handle (vitest / Node only). * * @param options - Client options, typically `{ host }` from `@brookesia/service/hosts/wifi` */ declare function configure(options: WifiModuleOptions): void; declare const wifi: { /** @returns `true` when the Wi-Fi service is registered on the device */available(): boolean; /** Release the Wi-Fi service binding. */ close(): void; /** * Read the Wi-Fi general state machine state. * @returns e.g. `'Disconnected'`, `'Connected'`, `'Scanning'` */ getGeneralState(): WifiGeneralState; /** * Trigger a general Wi-Fi action (maps to C++ `TriggerGeneralAction`). * * @param action - `'Init'` | `'Start'` | `'Stop'` | `'Connect'` | `'Disconnect'` */ triggerGeneralAction(action: WifiGeneralAction): void; /** * Set the AP to connect to (maps to C++ `SetConnectAp`). * * @param ssid - Network SSID * @param password - WPA passphrase; empty for open networks */ setConnectAp(ssid: string, password?: string): void; /** @returns Current connect-target AP info */ getConnectAp(): WifiConnectApInfo; /** @returns List of saved / connected AP records */ getConnectedAps(): WifiConnectApInfo[]; /** * Configure scan parameters (maps to C++ `SetScanParams`). * * @param params - `{ ap_count, interval_ms, timeout_ms }` */ setScanParams(params: WifiScanParams): void; /** Start Wi-Fi scanning (maps to C++ `TriggerScanStart`). */ triggerScanStart(): void; /** Stop Wi-Fi scanning (maps to C++ `TriggerScanStop`). */ triggerScanStop(): void; /** * Configure SoftAP parameters (maps to C++ `SetSoftApParams`). * * @param params - `{ ssid, password, max_connection }` */ setSoftApParams(params: WifiSoftApParams): void; /** @returns Current SoftAP configuration */ getSoftApParams(): WifiSoftApParams; /** Start SoftAP mode. */ triggerSoftApStart(): void; /** Stop SoftAP mode. */ triggerSoftApStop(): void; /** Enter SoftAP provisioning mode. */ triggerSoftApProvisionStart(): void; /** Exit SoftAP provisioning mode. */ triggerSoftApProvisionStop(): void; /** * Remove a saved AP from the connected list. * * @param ssid - SSID to remove */ removeConnectedAp(ssid: string): void; /** Load persisted Wi-Fi settings from NVS / Storage. */ loadData(): void; /** Reset Wi-Fi settings to factory defaults. */ resetData(): void; }; //#endregion export { WIFI_FUNCTIONS, WIFI_SERVICE_NAME, type WifiClientOptions, type WifiConnectApInfo, type WifiGeneralAction, type WifiGeneralState, type ServiceHandle as WifiHandle, type WifiModuleOptions, type WifiScanApInfo, type WifiScanParams, type WifiSoftApParams, closeWifi, configure, wifi as default, getConnectAp, getConnectedAps, getGeneralState, getSoftApParams, isWifiAvailable, openWifi, resetWifiData, setConnectAp, setScanParams, setSoftApParams, triggerGeneralAction, triggerScanStart, triggerScanStop, triggerSoftApProvisionStart, triggerSoftApProvisionStop, triggerSoftApStart, triggerSoftApStop }; //# sourceMappingURL=index.d.mts.map