Copyright (c) 2016-2018 Microchip Technology Inc.
and its subsidiaries.
#include "compiler.h"
Data Structures | |
struct | hif_msg_t |
struct | params_dispatch |
Macros | |
#define | MSG_CMD 5 |
#define | MSG_QUIT 4 |
#define | MSG_RX 1 |
#define | MSG_START 6 |
#define | MSG_TX_AP 3 |
#define | MSG_TX_STA 2 |
Typedefs | |
typedef void(* | wifi_task_cb )(void *arg) |
Functions | |
void | os_hook_deinit (void) |
uint8_t | os_hook_dispatch_no_wait (wifi_task_cb handler, void *p) |
Run handler function in the netif thread context and return immediately. More... | |
void | os_hook_dispatch_wait (wifi_task_cb handler, struct params_dispatch *p, void *pv) |
Run handler function in the netif thread context and wait for function return. More... | |
void | os_hook_init (void) |
Initialize netif thread. More... | |
void | os_hook_isr (void) |
Put interrupt request in netif queue for later processing. More... | |
void | os_hook_notify (void) |
Release lock to notify calling thread that netif job is done. More... | |
void | os_hook_send_start (wifi_task_cb handler, struct params_dispatch *p, void *pv) |
Start WiFi in the netif thread context and wait for function return. More... | |
void | os_hook_send_stop (wifi_task_cb handler, struct params_dispatch *p, void *pv) |
void | os_hook_set_handle (void *task) |
#define MSG_CMD 5 |
Referenced by os_hif_task(), os_hook_dispatch_no_wait(), and os_hook_dispatch_wait().
#define MSG_QUIT 4 |
#define MSG_RX 1 |
Referenced by os_hif_task(), and os_hook_isr().
#define MSG_START 6 |
Referenced by os_hif_task(), and os_hook_send_start().
#define MSG_TX_AP 3 |
Referenced by os_hif_task(), and wilc_netif_tx().
#define MSG_TX_STA 2 |
Referenced by os_hif_task(), wilc_netif_tx(), and wilc_netif_tx_from_queue().
typedef void(* wifi_task_cb)(void *arg) |
void os_hook_deinit | ( | void | ) |
uint8_t os_hook_dispatch_no_wait | ( | wifi_task_cb | handler, |
void * | p | ||
) |
Run handler function in the netif thread context and return immediately.
References hif_msg_t::handler, hif_thread, hif_msg_t::id, msg, MSG_CMD, hif_msg_t::priv, xQueueSend, and xTaskGetCurrentTaskHandle().
void os_hook_dispatch_wait | ( | wifi_task_cb | handler, |
struct params_dispatch * | p, | ||
void * | pv | ||
) |
Run handler function in the netif thread context and wait for function return.
References hif_msg_t::handler, hif_thread, hif_msg_t::id, msg, MSG_CMD, hif_msg_t::priv, params_dispatch::signal_semaphore, xQueueSend, xSemaphoreTake, and xTaskGetCurrentTaskHandle().
void os_hook_init | ( | void | ) |
Initialize netif thread.
References has_init, hif_thread, NULL, os_hif_task(), vSemaphoreCreateBinary, xQueueCreate, xSemaphoreTake, and xTaskCreate.
Referenced by os_m2m_wifi_init().
void os_hook_isr | ( | void | ) |
Put interrupt request in netif queue for later processing.
References hif_msg_t::id, msg, MSG_RX, NULL, osprintf(), hif_msg_t::payload, hif_msg_t::payload_size, hif_msg_t::pbuf, pdFALSE, pdTRUE, and xQueueSendFromISR.
void os_hook_notify | ( | void | ) |
Release lock to notify calling thread that netif job is done.
References xSemaphoreGive.
Referenced by os_m2m_wifi_connect_imp(), os_m2m_wifi_enable_ap_imp(), os_m2m_wifi_init_imp(), and os_m2m_wifi_set_max_tx_rate_imp().
void os_hook_send_start | ( | wifi_task_cb | handler, |
struct params_dispatch * | p, | ||
void * | pv | ||
) |
Start WiFi in the netif thread context and wait for function return.
References hif_msg_t::handler, hif_msg_t::id, msg, MSG_START, hif_msg_t::priv, params_dispatch::signal_semaphore, xQueueSend, and xSemaphoreTake.
Referenced by os_m2m_wifi_init().
void os_hook_send_stop | ( | wifi_task_cb | handler, |
struct params_dispatch * | p, | ||
void * | pv | ||
) |
void os_hook_set_handle | ( | void * | task | ) |
References hif_thread.
Referenced by os_m2m_wifi_init_imp().