NetBurner 3.0
nbWifiBsp.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 #define SPI_DEFAULT_BAUD 10000000 // 10 MHz
13 #define SPI_DEFAULT_WILC_BAUD 40000000 // 40 MHz
14 
15 namespace NBWifi {
16 namespace BSP {
17 
18 enum GPIO_Slave_Select {
19  ASSERT_SLAVE_SELECT = 0x0,
20  DEASSERT_SLAVE_SELECT = 0x1,
21 };
22 
23 void SetupIOPins( int spiModuleNum, int csSpiNum, int connectorNum, int csGpioPinNum, int resetPinNum);
24 
25 void InitSPI( int moduleNum, int csNum , uint32_t busSpeed = SPI_DEFAULT_BAUD);
26 
27 void StartSPI( int moduleNum, uint8_t *TxBuffer, uint8_t *RxBuffer, uint32_t len, OS_SEM *SPI_SEM, bool keepCsAsserted );
28 
29 void SetPin( int header, int pinNum, int state );
30 
31 void InitIRQFunc( int IRQNum, void (*handler)( void ) );
32 
33 void ResetIRQ( int IRQNum );
34 
35 void DisableIRQ( int IRQNum );
36 
37 void WifiReset( int resetPinNum = -1, int connectorNum = -1, int chipEnablePinNum = -1);
38 
39 }
40 }
41 
42 #endif /* ----- #ifndef __NBWIFIBSP_H ----- */
Semaphores are used to control access to shared resource critical section, or to communicate between ...
Definition: nbrtos.h:289
NBWifi namespace that encompaces the WiFi driver.
Definition: nbWifiBsp.h:15