Subversion Repositories Code-Repo

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
202 Kevin 1
#ifndef MAIN_H
2
#define	MAIN_H
3
 
4
#define UART_RX_TRIS TRISCbits.TRISC5
5
#define UART_TX_TRIS TRISCbits.TRISC4
6
#define UART_CTS_TRIS TRISCbits.TRISC3
7
#define UART_CTS_LAT LATCbits.LATC3
8
#define UART_RTS_TRIS TRISCbits.TRISC6
9
#define UART_RTS_LAT LATCbits.LATC6
10
 
11
#define I2C_CLK_TRIS TRISBbits.TRISB6
12
#define I2C_DAT_TRIS TRISBbits.TRISB4
13
 
14
#define LED_TRIS TRISCbits.TRISC1
15
#define LED_LAT LATCbits.LATC1
16
 
17
#define BLE_RESET_TRIS TRISCbits.TRISC7
18
#define BLE_RESET_LAT LATCbits.LATC7
19
 
20
#define BLE_SLEEP_TRIS TRISCbits.TRISC2
21
#define BLE_SLEEP_LAT LATCbits.LATC2
22
 
23
#define BLE_MODE_TRIS TRISCbits.TRISC0
24
#define BLE_MODE_LAT LATCbits.LATC0
25
 
26
#define ADDRESS_GYRO 0x6B
27
#define ADDRESS_ACCL 0x19
28
#define ADDRESS_MAGN 0x1E
29
#define ADDRESS_LIPO 0x36
30
 
31
#define _XTAL_FREQ 32000000
32
 
33
#endif	/* MAIN_H */
34
 
35
// <editor-fold defaultstate="collapsed" desc="Pinouts">
36
/*
37
1/RA3 - MCLR
38
2/RC5 - UART RX
39
3/RC4 - UART TX
40
4/RC3 - UART CTS
41
5/RC6 - UART RTS
42
6/RC7 - BLE RESET
43
7/RB7 - Acc Interrupt 1
44
8/RB6 - I2C SCL
45
9/RB5 - Mag Interrupt
46
10/RB4 - I2C SDA
47
11/RC2 - BLE SLEEP
48
12/RC1 - LED
49
13/RC0 - BLE Mode Toggle
50
14/RA2 - Gyro Interrupt 2
51
15/RA1 - ICSPCLK
52
16/RA0 - ISCLDAT
53
17/VSS - GND
54
18/VDD - VDD
55
19/RA5 - T1 OSO
56
20/RA4 - T1 OSO
57
*/
58
// </editor-fold>