Subversion Repositories Code-Repo

Rev

Rev 329 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
329 Kevin 1
#ifndef DEFINES_H
2
#define	DEFINES_H
3
 
4
#include <xc.h>
5
#include <stdint.h>
6
 
7
// <editor-fold defaultstate="collapsed" desc="I/O Pins">
8
 
9
// Resets the ECHO output for the next return signal
10
// Must be high at least 0.44ms
11
#define BLNK_TRIS   TRISCbits.TRISC4
12
#define BLNK_LAT    LATCbits.LATC4
13
 
14
// Starts the 16 pulse transmit
15
#define INIT_TRIS   TRISCbits.TRISC3
16
#define INIT_LAT    LATCbits.LATC3
17
 
18
// Ends the internal blanking early
19
#define BINH_TRIS   TRISCbits.TRISC2
20
#define BINH_LAT    LATCbits.LATC2
21
 
22
// 420kHz time base
23
#define OSC_TRIS    TRISAbits.TRISA5
24
 
25
// Return signal
26
#define ECHO_TRIS   TRISAbits.TRISA4
27
 
28
#define I2C_1_CLK_TRIS  TRISCbits.TRISC0
29
#define I2C_1_DAT_TRIS  TRISCbits.TRISC1
30
 
31
#define UART_RX_TRIS    TRISAbits.TRISA1
32
#define UART_TX_TRIS    TRISAbits.TRISA0
33
 
34
// </editor-fold>
35
 
36
#define _XTAL_FREQ      16000000
37
 
38
#endif	/* DEFINES_H */