Subversion Repositories Code-Repo

Compare Revisions

Problem with comparison.

Ignore whitespace Rev HEAD → Rev 201

/PIC Stuff/Cerebot_32MX7_LED_Cube/BTN.h
0,0 → 1,25
#ifndef BTN_H
#define BTN_H
 
// BTN1 = CN8, BTN2 = CN9, BTN3 = CN19
// BTN1 = RG6, BTN2 = RG7, BTN3 = RD13
// Note: Write to PORTx is effectively the same as write to LATx
#define BTN1_TRIS TRISGbits.TRISG6
#define BTN1_PORT PORTGbits.RG6
#define BTN2_TRIS TRISGbits.TRISG7
#define BTN2_PORT PORTGbits.RG7
#define BTN3_TRIS TRISDbits.TRISD13
#define BTN3_PORT PORTDbits.RD13
 
#define BTN_DEBOUNCE_MS 1
 
typedef struct {
void (*callback_function_1)(void);
void (*callback_function_2)(void);
void (*callback_function_3)(void);
} BTN_DATA;
 
void BTN_Init(BTN_DATA *data, void (*callback_1)(void), void (*callback_2)(void), void (*callback_3)(void));
 
#endif /* BTN_H */