Infuse-IoT SDK API 0.0.1
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
wifi_sim APIs

wifi_sim API More...

Functions

void wifi_sim_in_network_range (bool in_range)
 Simulate whether the device is in range of a network.
void wifi_sim_scan_results_set (const struct wifi_scan_result *results, size_t result_count)
 Configure scan results returned by the simulated device.
const struct wifi_scan_params * wifi_sim_scan_params_get (void)
 Get the latest scan parameters provided to the simulated device.
void wifi_sim_trigger_disconnect (void)
 If currently connected to a network, disconnect.

Detailed Description

wifi_sim API

Function Documentation

◆ wifi_sim_in_network_range()

void wifi_sim_in_network_range ( bool in_range)

#include </__w/infuse-sdk/infuse-sdk/infuse-sdk/include/infuse/drivers/wifi/wifi_sim.h>

Simulate whether the device is in range of a network.

Parameters
in_rangeTrue when in range, false otherwise

◆ wifi_sim_scan_params_get()

const struct wifi_scan_params * wifi_sim_scan_params_get ( void )

#include </__w/infuse-sdk/infuse-sdk/infuse-sdk/include/infuse/drivers/wifi/wifi_sim.h>

Get the latest scan parameters provided to the simulated device.

The returned object is owned by the simulated driver and is updated whenever NET_REQUEST_WIFI_SCAN is handled.

Returns
Latest scan parameters object

◆ wifi_sim_scan_results_set()

void wifi_sim_scan_results_set ( const struct wifi_scan_result * results,
size_t result_count )

#include </__w/infuse-sdk/infuse-sdk/infuse-sdk/include/infuse/drivers/wifi/wifi_sim.h>

Configure scan results returned by the simulated device.

The provided array must remain valid until this function is called again with a different array or a zero result count. Passing NULL or a zero count clears the simulated scan result list.

This function should not be called while a scan is ongoing, between NET_REQUEST_WIFI_SCAN and the final callback.

Parameters
resultsArray of scan results to return
result_countNumber of entries in results

◆ wifi_sim_trigger_disconnect()

void wifi_sim_trigger_disconnect ( void )

#include </__w/infuse-sdk/infuse-sdk/infuse-sdk/include/infuse/drivers/wifi/wifi_sim.h>

If currently connected to a network, disconnect.