20 #include "sl_wfx_configuration_defaults.h"
21 #include "sl_wfx_host_api.h"
22 #include "sl_wfx_version.h"
23 #include "bus/sl_wfx_bus.h"
24 #include "sl_wfx_registers.h"
32 #define WEAK __attribute__((weak))
57 uint8_t request_signal_active_level,
58 uint8_t priority_signal_active_level,
59 uint8_t freq_signal_active_level,
60 uint8_t grant_signal_active_level,
62 uint8_t default_grant_state,
63 uint8_t simultaneous_rx_access,
64 uint8_t priority_sampling_time,
65 uint8_t tx_rx_sampling_time,
66 uint8_t freq_sampling_time,
67 uint8_t grant_valid_time,
68 uint8_t fem_control_time,
69 uint8_t first_slot_time,
70 uint16_t periodic_tx_rx_sampling_time,
143 uint16_t passive_channel_time,
144 uint16_t num_probe_requestuests);
147 uint8_t rcpi_hysteresis,
148 uint8_t beacon_lost_count,
149 const uint8_t *channel_list,
150 uint8_t channel_list_count);
157 int32_t *max_tx_power_rf_port_2,
161 uint32_t *password_length,
167 uint16_t auth_data_length,
168 const uint8_t *auth_data);
174 uint32_t ssid_length,
178 uint8_t prevent_roaming,
179 uint16_t management_frame_protection,
180 const uint8_t *passkey,
181 uint16_t passkey_length,
182 const uint8_t *ie_data,
183 uint16_t ie_data_length);
188 const uint8_t *channel_list,
189 uint16_t channel_list_count,
191 uint16_t ssid_list_count,
192 const uint8_t *ie_data,
193 uint16_t ie_data_length,
194 const uint8_t *bssid);
200 uint32_t ssid_length,
202 uint8_t client_isolation,
204 uint8_t management_frame_protection,
205 const uint8_t *passkey,
206 uint16_t passkey_length,
207 const uint8_t *beacon_ie_data,
208 uint16_t beacon_ie_data_length,
209 const uint8_t *probe_response_ie_data,
210 uint16_t probe_response_ie_data_length);
213 uint16_t probe_response_ie_data_length,
214 uint32_t *beacon_ie_data,
215 uint32_t *probe_response_ie_data);
226 uint32_t buffer_size);
sl_status_t sl_wfx_disable_device_power_save(void)
Disable the power save feature in the FMAC driver and prevent the WFx going in sleep mode.
Definition: sl_wfx.c:1893
sl_status_t sl_wfx_receive_frame(uint16_t *ctrl_reg)
Receive available frame from the Wi-Fi chip.
Definition: sl_wfx.c:1653
sl_status_t sl_wfx_set_access_mode_message(void)
Set access mode message.
Definition: sl_wfx.c:1808
sl_status_t sl_wfx_allocate_command_buffer(sl_wfx_generic_message_t **buffer, uint32_t command_id, sl_wfx_buffer_type_t type, uint32_t buffer_size)
Allocate a buffer for the Wi-Fi driver.
Definition: sl_wfx.c:2426
sl_status_t sl_wfx_set_antenna_config(sl_wfx_antenna_config_t config)
Configure the antenna setting (done through the PDS)
Definition: sl_wfx.c:2259
sl_status_t sl_wfx_set_wake_up_bit(uint8_t state)
Set the Wi-Fi chip wake up bit.
Definition: sl_wfx.c:1830
sl_status_t sl_wfx_send_command(uint8_t command_id, void *data, uint32_t data_size, sl_wfx_interface_t interface, sl_wfx_generic_confirmation_t **response)
Send a command to WF200.
Definition: sl_wfx.c:1535
sl_status_t sl_wfx_free_command_buffer(sl_wfx_generic_message_t *buffer, uint32_t command_id, sl_wfx_buffer_type_t type)
Free a buffer for the Wi-Fi driver.
Definition: sl_wfx.c:2475
sl_status_t sl_wfx_init(sl_wfx_context_t *context)
Init the Wi-Fi chip.
Definition: sl_wfx.c:83
sl_status_t sl_wfx_get_opn(uint8_t **opn)
Get the part opn.
Definition: sl_wfx.c:2309
sl_status_t sl_wfx_send_request(uint8_t id, sl_wfx_generic_message_t *request, uint16_t request_length)
Send a request to the Wi-Fi chip.
Definition: sl_wfx.c:1589
sl_status_t sl_wfx_disable_irq(void)
Disable the Wi-Fi chip irq.
Definition: sl_wfx.c:1782
sl_status_t sl_wfx_enable_device_power_save(void)
Active the power save feature in the FMAC driver and let the WFx go in sleep mode.
Definition: sl_wfx.c:1859
sl_status_t sl_wfx_get_status_code(uint32_t wfx_status, uint8_t command_id)
Extract status code from WFx message.
Definition: sl_wfx.c:2328
sl_status_t sl_wfx_enable_irq(void)
Enable the Wi-Fi chip irq.
Definition: sl_wfx.c:1755
sl_status_t sl_wfx_deinit(void)
Deinit the Wi-Fi chip.
Definition: sl_wfx.c:250
sl_wfx_antenna_config_t
Enum listing the different antenna configurations.
Definition: sl_wfx_constants.h:289
sl_wfx_interface_t
Enum listing available interfaces in WFx Wi-Fi solution.
Definition: sl_wfx_constants.h:280
sl_wfx_buffer_type_t
Enumerates the different types of buffer.
Definition: sl_wfx_constants.h:314
sl_status_t sl_wfx_ext_auth(sl_wfx_ext_auth_data_type_t auth_data_type, uint16_t auth_data_length, const uint8_t *auth_data)
Send a WPA3 Auth packet.
Definition: sl_wfx.c:1190
sl_status_t sl_wfx_get_pmk(sl_wfx_password_t *password, uint32_t *password_length, sl_wfx_interface_t interface)
Get the PMK used to connect to the current secure network.
Definition: sl_wfx.c:1117
sl_status_t sl_wfx_add_multicast_address(const sl_wfx_mac_address_t *mac_address, sl_wfx_interface_t interface)
Add a multicast address to the multicast filter whitelist.
Definition: sl_wfx.c:779
sl_status_t sl_wfx_get_max_tx_power(int32_t *max_tx_power_rf_port_1, int32_t *max_tx_power_rf_port_2, sl_wfx_interface_t interface)
Set maximum transmit power.
Definition: sl_wfx.c:1085
sl_status_t sl_wfx_remove_multicast_address(const sl_wfx_mac_address_t *mac_address, sl_wfx_interface_t interface)
Remove a multicast address from the multicast filter whitelist.
Definition: sl_wfx.c:797
sl_status_t sl_wfx_send_join_command(const uint8_t *ssid, uint32_t ssid_length, const sl_wfx_mac_address_t *bssid, uint16_t channel, sl_wfx_security_mode_t security_mode, uint8_t prevent_roaming, uint16_t management_frame_protection, const uint8_t *passkey, uint16_t passkey_length, const uint8_t *ie_data, uint16_t ie_data_length)
As a station, send a command to join a Wi-Fi network.
Definition: sl_wfx.c:328
sl_status_t sl_wfx_get_signal_strength(uint32_t *rcpi)
Get the signal strength of the last packets received.
Definition: sl_wfx.c:707
sl_status_t sl_wfx_set_max_ap_client(uint32_t max_clients)
Configure the maximum number of clients supported in softap mode.
Definition: sl_wfx.c:921
sl_status_t sl_wfx_add_blacklist_address(const sl_wfx_mac_address_t *mac_address)
Add a mac address to the device blacklist.
Definition: sl_wfx.c:901
sl_status_t sl_wfx_disconnect_ap_client_command(const sl_wfx_mac_address_t *client)
In AP mode, disconnect the specified client.
Definition: sl_wfx.c:735
sl_status_t sl_wfx_set_roam_parameters(uint8_t rcpi_threshold, uint8_t rcpi_hysteresis, uint8_t beacon_lost_count, const uint8_t *channel_list, uint8_t channel_list_count)
Configure the roaming behavior in station mode.
Definition: sl_wfx.c:991
sl_status_t sl_wfx_set_power_mode(sl_wfx_pm_mode_t mode, sl_wfx_pm_poll_t strategy, uint16_t interval)
Set the power mode used as a station. The Wi-Fi chip will enable the Wi-Fi power mode feature.
Definition: sl_wfx.c:759
sl_status_t sl_wfx_set_max_tx_power(int32_t max_tx_power, sl_wfx_interface_t interface)
Set maximum transmit power.
Definition: sl_wfx.c:1064
sl_status_t sl_wfx_set_mac_address(const sl_wfx_mac_address_t *mac, sl_wfx_interface_t interface)
Definition: sl_wfx.c:282
sl_status_t sl_wfx_set_ns_ip_address(uint8_t *ns_ip_addr, uint8_t num_ns_ip_addr)
Set the NS offloading state.
Definition: sl_wfx.c:834
sl_status_t sl_wfx_send_stop_scan_command(void)
Stop an ongoing scan process.
Definition: sl_wfx.c:693
sl_status_t sl_wfx_add_whitelist_address(const sl_wfx_mac_address_t *mac_address)
Add a mac address to the device whitelist.
Definition: sl_wfx.c:885
sl_status_t sl_wfx_set_max_ap_client_inactivity(uint32_t inactivity_timeout)
Configure the maximum client idle time.
Definition: sl_wfx.c:940
sl_status_t sl_wfx_set_broadcast_filter(uint32_t filter)
Set the broadcast filter state.
Definition: sl_wfx.c:854
sl_status_t sl_wfx_set_arp_ip_address(uint32_t *arp_ip_addr, uint8_t num_arp_ip_addr)
Set the ARP offloading state.
Definition: sl_wfx.c:813
sl_status_t sl_wfx_get_ap_client_signal_strength(const sl_wfx_mac_address_t *client, uint32_t *signal_strength)
Get the signal strength of the last packets received from an AP client.
Definition: sl_wfx.c:1153
sl_status_t sl_wfx_set_tx_rate_parameters(sl_wfx_rate_set_bitmask_t rate_set_bitmask)
Set the rate mode allowed by the station once connected.
Definition: sl_wfx.c:1045
sl_status_t sl_wfx_stop_ap_command(void)
Send a command to stop the softap mode.
Definition: sl_wfx.c:550
sl_status_t sl_wfx_set_unicast_filter(uint32_t filter)
Set the unicast filter state.
Definition: sl_wfx.c:869
sl_status_t sl_wfx_send_scan_command(uint16_t scan_mode, const uint8_t *channel_list, uint16_t channel_list_count, const sl_wfx_ssid_def_t *ssid_list, uint16_t ssid_list_count, const uint8_t *ie_data, uint16_t ie_data_length, const uint8_t *bssid)
Send a scan command.
Definition: sl_wfx.c:611
sl_status_t sl_wfx_send_disconnect_command(void)
Connected as a station, send a disconnection request to the AP.
Definition: sl_wfx.c:398
sl_status_t sl_wfx_start_ap_command(uint16_t channel, uint8_t *ssid, uint32_t ssid_length, uint8_t hidden_ssid, uint8_t client_isolation, sl_wfx_security_mode_t security_mode, uint8_t management_frame_protection, const uint8_t *passkey, uint16_t passkey_length, const uint8_t *beacon_ie_data, uint16_t beacon_ie_data_length, const uint8_t *probe_response_ie_data, uint16_t probe_response_ie_data_length)
Send a command to start the softap mode.
Definition: sl_wfx.c:429
sl_status_t sl_wfx_set_scan_parameters(uint16_t active_channel_time, uint16_t passive_channel_time, uint16_t num_probe_requestuests)
Configure scan parameters.
Definition: sl_wfx.c:963
sl_status_t sl_wfx_update_ap_command(uint16_t beacon_ie_data_length, uint16_t probe_response_ie_data_length, uint32_t *beacon_ie_data, uint32_t *probe_response_ie_data)
Update the softap settings.
Definition: sl_wfx.c:502
sl_status_t sl_wfx_send_ethernet_frame(sl_wfx_send_frame_req_t *frame, uint32_t data_length, sl_wfx_interface_t interface, uint8_t priority)
Send an Ethernet frame.
Definition: sl_wfx.c:567
sl_status_t sl_wfx_set_cca_config(uint8_t cca_thr_mode)
Send a request to configure the CCA mode.
Definition: sl_wfx.c:1448
sl_status_t sl_wfx_pta_priority(uint32_t priority)
Send a request to define the level of priority used to arbitrate concurrent Coex and Wlan requests.
Definition: sl_wfx.c:1406
sl_status_t sl_wfx_pta_state(uint32_t pta_state)
Send a request to start or stop the PTA.
Definition: sl_wfx.c:1427
sl_status_t sl_wfx_pta_settings(uint8_t pta_mode, uint8_t request_signal_active_level, uint8_t priority_signal_active_level, uint8_t freq_signal_active_level, uint8_t grant_signal_active_level, uint8_t coex_type, uint8_t default_grant_state, uint8_t simultaneous_rx_access, uint8_t priority_sampling_time, uint8_t tx_rx_sampling_time, uint8_t freq_sampling_time, uint8_t grant_valid_time, uint8_t fem_control_time, uint8_t first_slot_time, uint16_t periodic_tx_rx_sampling_time, uint16_t coex_quota, uint16_t wlan_quota)
Send a request to set the PTA mode, the active levels on signals, the Coex type, to define the timing...
Definition: sl_wfx.c:1350
sl_status_t sl_wfx_prevent_rollback(uint32_t magic_word)
Prevent Rollback request.
Definition: sl_wfx.c:1469
sl_status_t sl_wfx_send_configuration(const char *pds_data, uint32_t pds_data_length)
Function to send PDS chunks.
Definition: sl_wfx.c:1249
sl_status_t sl_wfx_shutdown(void)
Shutdown the Wi-Fi chip.
Definition: sl_wfx.c:1487
sl_status_t sl_wfx_control_gpio(uint8_t gpio_label, uint8_t gpio_mode, uint32_t *value)
Send a request to read or write a GPIO.
Definition: sl_wfx.c:1296
enum sl_wfx_ext_auth_data_type_e sl_wfx_ext_auth_data_type_t
Type of the authentication message.
enum sl_wfx_security_mode_e sl_wfx_security_mode_t
Security mode of a network.
enum sl_wfx_pm_mode_e sl_wfx_pm_mode_t
Device power management mode.
enum sl_wfx_pm_poll_e sl_wfx_pm_poll_t
Device power save polling strategy.
Structure used to maintain the Wi-Fi solution context on the host side.
Definition: sl_wfx_constants.h:400
Generic confirmation message with the body reduced to the status field.
Definition: sl_wfx_general_api.h:137
Generic message structure for all requests, confirmations and indications.
Definition: sl_wfx_general_api.h:124
Structure to handle MAC address format.
Definition: sl_wfx_constants.h:363
Structure to handle password format.
Definition: sl_wfx_constants.h:371
Device TX rate set bitmask used in sl_wfx_set_tx_rate_parameters_req_body_t.
Definition: sl_wfx_cmd_api.h:411
Request message for sending a packet to the network.
Definition: sl_wfx_cmd_api.h:1601
Service Set Identifier (SSID) of a network.
Definition: sl_wfx_cmd_api.h:384