17 #ifndef SL_WFX_HOST_API_H
18 #define SL_WFX_HOST_API_H
20 #include "sl_wfx_api.h"
21 #include "sl_wfx_constants.h"
179 void **event_payload_out);
214 uint32_t buffer_size);
304 uint16_t header_length,
306 uint16_t buffer_length);
337 uint16_t buffer_length);
345 #ifdef SL_WFX_USE_SECURE_LINK
355 sl_status_t sl_wfx_host_get_secure_link_mac_key(uint8_t *sl_mac_key);
376 const uint8_t *sl_mac_key,
377 uint8_t *sl_host_pub_key);
384 sl_status_t sl_wfx_host_free_crypto_context(
void);
394 sl_status_t sl_wfx_host_decode_secure_link_data(uint8_t *buffer,
396 uint8_t *session_key);
408 uint32_t data_length,
409 uint8_t *session_key,
417 sl_status_t sl_wfx_host_schedule_secure_link_renegotiation(
void);
427 #if SL_WFX_DEBUG_MASK
428 extern void sl_wfx_host_log(
const char *
string, ...);
sl_wfx_buffer_type_t
Enumerates the different types of buffer.
Definition: sl_wfx_constants.h:314
sl_wfx_register_address_t
Enum listing the registers of the WFx solution.
Definition: sl_wfx_constants.h:251
sl_wfx_host_bus_transfer_type_t
Enumerates the different types of bus transfers.
Definition: sl_wfx_constants.h:324
sl_status_t sl_wfx_host_disable_platform_interrupt(void)
Disable the bus interrupt.
Definition: sl_wfx_host_spi.c:153
sl_status_t sl_wfx_host_wait_for_confirmation(uint8_t confirmation_id, uint32_t timeout_ms, void **event_payload_out)
Called when the driver is waiting for a confirmation.
Definition: sl_wfx_host.c:226
sl_status_t sl_wfx_host_enable_platform_interrupt(void)
Enable the bus interrupt.
Definition: sl_wfx_host_spi.c:143
sl_status_t sl_wfx_host_init_bus(void)
Initialize the host bus.
Definition: sl_wfx_host_spi.c:107
sl_status_t sl_wfx_host_wait_for_wake_up(void)
Called once the WFx chip is waking up.
Definition: sl_wfx_host.c:191
sl_status_t sl_wfx_host_get_pds_size(uint16_t *pds_size)
Driver hook to get the number of lines of the PDS.
Definition: sl_wfx_host.c:146
sl_status_t sl_wfx_host_sleep_grant(sl_wfx_host_bus_transfer_type_t type, sl_wfx_register_address_t address, uint32_t length)
Called when the driver is considering putting the WFx in sleep mode.
Definition: sl_wfx_host.c:206
sl_status_t sl_wfx_host_get_pds_data(const char **pds_data, uint16_t index)
Driver hook to retrieve a PDS line.
Definition: sl_wfx_host.c:136
sl_status_t sl_wfx_host_wait(uint32_t wait_ms)
Called when the FMAC driver wants to add a delay.
Definition: sl_wfx_host.c:254
sl_status_t sl_wfx_host_allocate_buffer(void **buffer, sl_wfx_buffer_type_t type, uint32_t buffer_size)
Called when the driver wants to allocate memory.
Definition: sl_wfx_host.c:380
sl_status_t sl_wfx_host_unlock(void)
Called when the driver needs to unlock its access.
Definition: sl_wfx_host.c:451
sl_status_t sl_wfx_host_transmit_frame(void *frame, uint32_t frame_len)
Called when the driver sends a frame to the WFx chip.
Definition: sl_wfx_host.c:432
sl_status_t sl_wfx_host_sdio_enable_high_speed_mode(void)
Enable the SDIO high-speed mode.
sl_status_t sl_wfx_host_post_event(sl_wfx_generic_message_t *event_payload)
Called when a message is received from the WFx chip.
Definition: sl_wfx_host.c:260
sl_status_t sl_wfx_host_sdio_transfer_cmd52(sl_wfx_host_bus_transfer_type_t type, uint8_t function, uint32_t address, uint8_t *buffer)
Send command 52 on the SDIO bus.
sl_status_t sl_wfx_host_spi_transfer_no_cs_assert(sl_wfx_host_bus_transfer_type_t type, uint8_t *header, uint16_t header_length, uint8_t *buffer, uint16_t buffer_length)
Send data on the SPI bus.
Definition: sl_wfx_host_spi.c:184
sl_status_t sl_wfx_host_deinit_bus(void)
Deinitialize the host bus.
Definition: sl_wfx_host_spi.c:163
sl_status_t sl_wfx_host_free_buffer(void *buffer, sl_wfx_buffer_type_t type)
Called when the driver wants to free memory.
Definition: sl_wfx_host.c:423
sl_status_t sl_wfx_host_deinit(void)
Driver hook to deinitialize the host resources.
Definition: sl_wfx_host.c:156
sl_status_t sl_wfx_host_set_wake_up_pin(uint8_t state)
Drive the wake up pin in the requested state.
Definition: sl_wfx_host.c:173
sl_status_t sl_wfx_host_reset_chip(void)
Implement the reset of the WFx chip.
Definition: sl_wfx_host.c:161
sl_status_t sl_wfx_host_init(void)
Driver hook to initialize the host resources.
Definition: sl_wfx_host.c:101
sl_status_t sl_wfx_host_get_firmware_size(uint32_t *firmware_size)
Driver hook to retrieve the firmware size.
Definition: sl_wfx_host.c:126
sl_status_t sl_wfx_host_hold_in_reset(void)
Hold the WFx chip in reset mode.
Definition: sl_wfx_host.c:213
sl_status_t sl_wfx_host_get_firmware_data(const uint8_t **data, uint32_t data_size)
Driver hook to retrieve a firmware chunk.
Definition: sl_wfx_host.c:111
sl_status_t sl_wfx_host_setup_waited_event(uint8_t event_id)
Set up the next event that the driver will wait.
Definition: sl_wfx_host.c:219
sl_status_t sl_wfx_host_spi_cs_assert(void)
Assert the SPI Chip Select pin.
Definition: sl_wfx_host_spi.c:172
sl_status_t sl_wfx_host_sdio_transfer_cmd53(sl_wfx_host_bus_transfer_type_t type, uint8_t function, uint32_t address, uint8_t *buffer, uint16_t buffer_length)
Send command 53 on the SDIO bus.
sl_status_t sl_wfx_host_lock(void)
Called when the driver needs to lock its access.
Definition: sl_wfx_host.c:437
sl_status_t sl_wfx_host_spi_cs_deassert(void)
Deassert the SPI Chip Select pin.
Definition: sl_wfx_host_spi.c:178
Structure used to maintain the Wi-Fi solution context on the host side.
Definition: sl_wfx_constants.h:400
Generic message structure for all requests, confirmations and indications.
Definition: sl_wfx_general_api.h:124
Definition: sl_wfx_general_api.h:644
Exchange Secure Link Public Keys.
Definition: sl_wfx_general_api.h:610