Subversion Repositories Code-Repo

Rev

Rev 152 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 152 Rev 155
Line 3... Line 3...
3
 
3
 
4
#define UART1_RX_TO_BUFFER
4
#define UART1_RX_TO_BUFFER
5
//#define UART1_RX_TO_XBEE
5
//#define UART1_RX_TO_XBEE
6
 
6
 
7
#define _DEBUG
7
#define _DEBUG
-
 
8
 
8
//#define _TEST_UART
9
//#define _TEST_UART
9
//#define _TEST_I2C_MASTER
10
//#define _TEST_I2C_MASTER
10
//#define _TEST_I2C_SLAVE
11
//#define _TEST_I2C_SLAVE
11
//#define _TEST_SPI
12
//#define _TEST_SPI
12
//#define _TEST_NFC
13
//#define _TEST_NFC
13
//#define _TEST_LED_BACKPACK
14
//#define _TEST_LED_BACKPACK
14
//#define _TEST_SSD1306_OLED
15
//#define _TEST_SSD1306_OLED
15
//#define _TEST_SSD1331_OLED
16
//#define _TEST_SSD1331_OLED
-
 
17
//#define _TEST_TIMER1_RTC
-
 
18
//#define _TEST_LUX
-
 
19
//#define _TEST_OLED_CHAR
-
 
20
//#define _TEST_NFC_TO_SSD1306_OLED
-
 
21
//#define _TEST_LUX_TO_CHAR_OLED
16
//#define _TEST_ADC
22
//#define _TEST_ADC
-
 
23
//#define _TEST_BMP //TODO: Test this again once compiler is fixed
-
 
24
//#define _TEST_XBEE // TODO: Reimplement this
-
 
25
 
-
 
26
 
-
 
27
 
-
 
28
 
17
//#define _TEST_XBEE
29
//#define _TEST_BMP
18
 
30
 
19
// Enable or disable debug prints depending on project preprocessor (_DEBUG)
31
// Enable or disable debug prints depending on project preprocessor (_DEBUG)
20
#ifdef _DEBUG
32
#ifdef _DEBUG
21
#define DBG_PRINT_MAIN UART1_WriteS
33
#define DBG_PRINT_MAIN UART1_WriteS
22
#define DBG_PRINT_UART(x) UART1_WriteS(x)
34
#define DBG_PRINT_UART UART1_WriteS
23
#define DBG_PRINT_I2C(x) UART1_WriteS(x)
35
#define DBG_PRINT_I2C UART1_WriteS
24
#define DBG_PRINT_SPI(x) UART1_WriteS(x)
36
#define DBG_PRINT_SPI UART1_WriteS
25
#define DBG_PRINT_XBEE(x) UART1_WriteS(x)
37
#define DBG_PRINT_XBEE UART1_WriteS
26
#define DBG_PRINT_PORTB_INT(x)
38
#define DBG_PRINT_PORTB_INT
27
#define DBG_PRINT_INT(x)
39
#define DBG_PRINT_INT
-
 
40
#define DBG_PRINT_LUX
28
#define DBG_PRINT_BUFFER(x)
41
#define DBG_PRINT_BMP
29
#else
42
#else
30
#define DBG_PRINT_MAIN(x)
43
#define DBG_PRINT_MAIN
31
#define DBG_PRINT_UART(x)
44
#define DBG_PRINT_UART
32
#define DBG_PRINT_I2C(x)
45
#define DBG_PRINT_I2C
33
#define DBG_PRINT_SPI(x)
46
#define DBG_PRINT_SPI
34
#define DBG_PRINT_XBEE(x)
47
#define DBG_PRINT_XBEE
35
#define DBG_PRINT_PORTB_INT(x)
48
#define DBG_PRINT_PORTB_INT
36
#define DBG_PRINT_INT(x)
49
#define DBG_PRINT_INT
-
 
50
#define DBG_PRINT_LUX
37
#define DBG_PRINT_BUFFER(x)
51
#define DBG_PRINT_BMP
38
#endif
52
#endif
39
 
53
 
40
// Pin allocations
54
// Pin allocations
41
#define UART1_RX_TRIS           TRISCbits.TRISC7
55
#define UART1_RX_TRIS           TRISCbits.TRISC7
42
#define UART1_TX_TRIS           TRISCbits.TRISC6
56
#define UART1_TX_TRIS           TRISCbits.TRISC6