SZS ez430-RF2480 1.0

ZigBee Sensor Network with synchronized time and time-stamped measurements.
spi.h
Go to the documentation of this file.
1 /*
2  * spi.h
3  *
4  * Created on: 31/10/2013
5  * Author: Fernando
6  */
7 
16 #ifndef SPI_H_
17 #define SPI_H_
18 
19 /*
20  * ======== Includes ========
21  */
22 
23 #include <xdc/std.h>
24 
25 /*
26  * ======== Doxygen ========
27  */
36 /*
37  * ======== Constants ========
38  */
39 
40 /*
41  * ======== Macros ========
42  */
43 
47 #define SPI_BUFSIZE 128
48 
49 /*
50  * ======== Types ========
51  */
52 
53 /*
54  * ======== Global Variables ========
55  */
56 
57 extern char spi_buf[SPI_BUFSIZE];
58 
59 /*
60  * ======== Global Functions ========
61  */
62 
63 void spi_init();
64 UInt16 spi_proccess();
65 
66 UInt8 spi_reqBegin(UInt8 len, UInt8 cmd0, UInt8 cmd1);
67 UInt8 spi_reqData(UInt8 len, void *pBuf);
68 void spi_reqEnd(UInt8 forwardToSerial);
69 
70 UInt8 spi_busy();
71 
72 void SPI_SRDYISR();
73 void SPI_USCIB0RX_ISR();
74 
78 #endif /* SPI_H_ */
void SPI_SRDYISR()
ISR SRDY.
Definition: spi.c:569
UInt8 spi_reqBegin(UInt8 len, UInt8 cmd0, UInt8 cmd1)
Request begin.
Definition: spi.c:352
UInt8 spi_reqData(UInt8 len, void *pBuf)
Request data.
Definition: spi.c:382
void SPI_USCIB0RX_ISR()
USCIB0 RX.
Definition: spi.c:625
UInt8 spi_busy()
SPI busy.
Definition: spi.c:444
char spi_buf[SPI_BUFSIZE]
SPI buffer, used to send and receive data.
Definition: spi.c:172
UInt16 spi_proccess()
SPI proccess.
Definition: spi.c:325
#define SPI_BUFSIZE
Size of the SPI buffer.
Definition: spi.h:47
void spi_reqEnd(UInt8 forwardToSerial)
Request end.
Definition: spi.c:411
void spi_init()
SPI initialization.
Definition: spi.c:287