NetBurner 3.5.6
PDF Version
wifiBsp.h
Go to the documentation of this file.
1/*NB_REVISION*/
2
3/*NB_COPYRIGHT*/
4
9#ifndef __NBWIFIBSP_H
10#define __NBWIFIBSP_H
11
12#include <wifi/wifiDriver.h>
13
14#define SPI_DEFAULT_BAUD 10000000 // 10 MHz
15#define SPI_DEFAULT_WILC_BAUD 40000000 // 40 MHz
16
17namespace NB
18{
19namespace WifiBSP
20{
21
22enum GPIO_Slave_Select
23{
24 ASSERT_SLAVE_SELECT = 0x0,
25 DEASSERT_SLAVE_SELECT = 0x1,
26};
27
28void SetupIOPins(int spiModuleNum, int csSpiNum, int connectorNum, int csGpioPinNum, int resetPinNum);
29
30void InitSPI(int moduleNum, int csNum, uint32_t busSpeed = SPI_DEFAULT_BAUD);
31
32void StartSPI(int moduleNum, uint8_t *TxBuffer, uint8_t *RxBuffer, uint32_t len, OS_SEM *SPI_SEM, bool keepCsAsserted);
33
34void SetPin(int header, int pinNum, int state);
35
36void InitIRQFunc(int IRQNum, void (*handler)(void), wifiModule wifiPlatform);
37
38void ResetIRQ(int IRQNum);
39
40void DisableIRQ(int IRQNum);
41
42void WifiReset(int resetPinNum = -1, int connectorNum = -1, int chipEnablePinNum = -1);
43
44} // namespace WifiBSP
45} // namespace NB
46
47#endif /* ----- #ifndef __NBWIFIBSP_H ----- */
Semaphores are used to control access to shared resources or or to communicate between tasks in a mul...
Definition nbrtos.h:411
NetBurner Wifi API.