24 #include "mbed_debug.h" 25 #include "mbed_error.h" 34 PinName mosi = MBED_CONF_EMW3080B_WIFI_MOSI,
35 PinName miso = MBED_CONF_EMW3080B_WIFI_MISO,
36 PinName sclk = MBED_CONF_EMW3080B_WIFI_SCLK,
37 PinName nss = MBED_CONF_EMW3080B_WIFI_NSS,
38 PinName notify = MBED_CONF_EMW3080B_WIFI_NOTIFY,
39 PinName flow = MBED_CONF_EMW3080B_WIFI_FLOW,
40 PinName reset = MBED_CONF_EMW3080B_WIFI_RESET
54 void notify_rise(
void);
55 int8_t wait_flow_high(uint32_t timeout);
57 SEM_DECLARE(spi_txrx_sem);
58 SEM_DECLARE(spi_flow_rise_sem);
59 SEM_DECLARE(spi_transfer_done_sem);
61 uint8_t *spi_tx_data = NULL;
62 uint16_t spi_tx_len = 0;
64 int32_t TransmitReceive(uint8_t *txdata, uint8_t *rxdata, uint32_t datalen, uint32_t timeout);
65 int32_t Transmit(uint8_t *txdata, uint32_t datalen, uint32_t timeout);
66 int32_t Receive(uint8_t *rxdata, uint32_t datalen, uint32_t timeout);
67 void spi_handler(
int event);
69 int8_t mx_wifi_spi_txrx_start(
void);
70 int8_t mx_wifi_spi_txrx_stop(
void);
72 THREAD_DECLARE(MX_WIFI_TxRxThreadId);
77 int8_t IO_Init(uint16_t mode);
78 int8_t IO_DeInit(
void);
79 void IO_Delay(uint32_t delayms);
80 uint16_t IO_Send(uint8_t *data, uint16_t len);
81 uint16_t IO_Receive(uint8_t *buffer, uint16_t buff_size);
82 void process_txrx_poll(uint32_t timeout);
Header for mx_wifi.c module.
Header for mx_wifi_hci.c module.
A digital interrupt input, used to call a function on a rising or falling edge.
A digital output, used for setting the state of a pin.
A SPI Master, used for communicating with SPI slave devices.
A digital input, used for reading the state of a pin.