Subversion Repositories Code-Repo

Rev

Rev 253 | Blame | Compare with Previous | Last modification | View Log | RSS feed

// PIC32MX795F512L

#include <xc.h>
#include <plib.h>
#include <stdint.h>

#ifndef DEFINES_H
#define DEFINES_H

// Uncomment ONE of the following:
#define CEREBOT_32MX7
// #define CEREBOT_MX7CK

#define LED1_TRIS TRISGbits.TRISG12
#define LED1_LAT LATGbits.LATG12
#define LED2_TRIS TRISGbits.TRISG13
#define LED2_LAT LATGbits.LATG13
#define LED3_TRIS TRISGbits.TRISG14
#define LED3_LAT LATGbits.LATG14
#define LED4_TRIS TRISGbits.TRISG15
#define LED4_LAT LATGbits.LATG15

#define CPU_CLOCK_HZ    80000000UL
#define PERIPHERAL_CLOCK_HZ 80000000UL
#define CPU_CT_HZ       (CPU_CLOCK_HZ/2UL)
#define MS_TO_CT_TICKS  (CPU_CLOCK_HZ/2000UL)
#define US_TO_CT_TICKS  (CPU_CLOCK_HZ/2000000UL)

#endif  /* DEFINES_H */