X-Git-Url: http://cloudbase.mooo.com/gitweb/irmp.git/blobdiff_plain/93570cd97cecf623cf97269629090259826f93ee..cea9614894a5e560540dadc2e480fb64ec0451e1:/irmpconfig.h diff --git a/irmpconfig.h b/irmpconfig.h index 5afe094..225a0e4 100644 --- a/irmpconfig.h +++ b/irmpconfig.h @@ -3,7 +3,7 @@ * * Copyright (c) 2009-2011 Frank Meyer - frank(at)fli4l.de * - * $Id: irmpconfig.h,v 1.74 2011/09/11 13:17:38 fm Exp $ + * $Id: irmpconfig.h,v 1.80 2012/02/21 08:41:46 fm Exp $ * * ATMEGA88 @ 8 MHz * @@ -62,6 +62,7 @@ #define IRMP_SUPPORT_NOKIA_PROTOCOL 0 // Nokia >= 10000 ~300 bytes // exotic protocols, enable here! Enable Remarks F_INTERRUPTS Program Space +#define IRMP_SUPPORT_GRUNDIG2_PROTOCOL 0 // Grundig TP400 >= 10000 ~300 bytes #define IRMP_SUPPORT_KATHREIN_PROTOCOL 0 // Kathrein >= 10000 ~200 bytes #define IRMP_SUPPORT_NUBERT_PROTOCOL 0 // NUBERT >= 10000 ~50 bytes #define IRMP_SUPPORT_BANG_OLUFSEN_PROTOCOL 0 // Bang & Olufsen >= 10000 ~200 bytes @@ -79,17 +80,19 @@ * Change hardware pin here: *--------------------------------------------------------------------------------------------------------------------------------------------------- */ -#ifdef PIC_CCS_COMPILER // PIC CCS Compiler: +#if defined (PIC_C18) // Microchip C18 Compiler +#include // main PIC18 h file +#define IRMP_PIN PORTBbits.RB4 // use RB4 as IR input on PIC +#define input(x) (x) -#define IRMP_PIN PIN_B4 // use PB4 as IR input on PIC - -#else // AVR: +#elif defined (PIC_CCS_COMPILER) // PIC CCS Compiler: +#define IRMP_PIN PIN_B4 // use PB4 as IR input on PIC +#else // AVR: #define IRMP_PORT PORTB #define IRMP_DDR DDRB #define IRMP_PIN PINB -#define IRMP_BIT 6 // use PB6 as IR input on AVR - +#define IRMP_BIT 6 // use PB6 as IR input on AVR #define input(x) ((x) & (1 << IRMP_BIT)) #endif @@ -101,6 +104,15 @@ #define IRMP_LOGGING 0 // 1: log IR signal (scan), 0: do not (default) #endif +/*--------------------------------------------------------------------------------------------------------------------------------------------------- + * Use external logging routines + * If you enable external logging, you have also to enable IRMP_LOGGING above + *--------------------------------------------------------------------------------------------------------------------------------------------------- + */ +#ifndef IRMP_EXT_LOGGING +#define IRMP_EXT_LOGGING 0 // 1:log, 0: do not log ; +#endif + /*--------------------------------------------------------------------------------------------------------------------------------------------------- * Set IRMP_PROTOCOL_NAMES to 1 if want to access protocol names (for logging etc), costs ~300 bytes RAM! *--------------------------------------------------------------------------------------------------------------------------------------------------- @@ -118,51 +130,51 @@ *--------------------------------------------------------------------------------------------------------------------------------------------------- */ #if IRMP_SUPPORT_SIEMENS_PROTOCOL == 1 && F_INTERRUPTS < 15000 -#warning F_INTERRUPTS too low, SIEMENS protocol disabled (should be at least 15000) -#undef IRMP_SUPPORT_SIEMENS_PROTOCOL -#define IRMP_SUPPORT_SIEMENS_PROTOCOL 0 +# warning F_INTERRUPTS too low, SIEMENS protocol disabled (should be at least 15000) +# undef IRMP_SUPPORT_SIEMENS_PROTOCOL +# define IRMP_SUPPORT_SIEMENS_PROTOCOL 0 #endif #if IRMP_SUPPORT_RUWIDO_PROTOCOL == 1 && F_INTERRUPTS < 15000 -#warning F_INTERRUPTS too low, RUWIDO protocol disabled (should be at least 15000) -#undef IRMP_SUPPORT_RUWIDO_PROTOCOL -#define IRMP_SUPPORT_RUWIDO_PROTOCOL 0 +# warning F_INTERRUPTS too low, RUWIDO protocol disabled (should be at least 15000) +# undef IRMP_SUPPORT_RUWIDO_PROTOCOL +# define IRMP_SUPPORT_RUWIDO_PROTOCOL 0 #endif #if IRMP_SUPPORT_RECS80_PROTOCOL == 1 && F_INTERRUPTS < 15000 -#warning F_INTERRUPTS too low, RECS80 protocol disabled (should be at least 15000) -#undef IRMP_SUPPORT_RECS80_PROTOCOL -#define IRMP_SUPPORT_RECS80_PROTOCOL 0 +# warning F_INTERRUPTS too low, RECS80 protocol disabled (should be at least 15000) +# undef IRMP_SUPPORT_RECS80_PROTOCOL +# define IRMP_SUPPORT_RECS80_PROTOCOL 0 #endif #if IRMP_SUPPORT_RECS80EXT_PROTOCOL == 1 && F_INTERRUPTS < 15000 -#warning F_INTERRUPTS too low, RECS80EXT protocol disabled (should be at least 15000) -#undef IRMP_SUPPORT_RECS80EXT_PROTOCOL -#define IRMP_SUPPORT_RECS80EXT_PROTOCOL 0 +# warning F_INTERRUPTS too low, RECS80EXT protocol disabled (should be at least 15000) +# undef IRMP_SUPPORT_RECS80EXT_PROTOCOL +# define IRMP_SUPPORT_RECS80EXT_PROTOCOL 0 #endif #if IRMP_SUPPORT_LEGO_PROTOCOL == 1 && F_INTERRUPTS < 20000 -#warning F_INTERRUPTS too low, LEGO protocol disabled (should be at least 20000) -#undef IRMP_SUPPORT_LEGO_PROTOCOL -#define IRMP_SUPPORT_LEGO_PROTOCOL 0 +# warning F_INTERRUPTS too low, LEGO protocol disabled (should be at least 20000) +# undef IRMP_SUPPORT_LEGO_PROTOCOL +# define IRMP_SUPPORT_LEGO_PROTOCOL 0 #endif #if IRMP_SUPPORT_JVC_PROTOCOL == 1 && IRMP_SUPPORT_NEC_PROTOCOL == 0 -#warning JVC protocol needs also NEC protocol, NEC protocol enabled -#undef IRMP_SUPPORT_NEC_PROTOCOL -#define IRMP_SUPPORT_NEC_PROTOCOL 1 +# warning JVC protocol needs also NEC protocol, NEC protocol enabled +# undef IRMP_SUPPORT_NEC_PROTOCOL +# define IRMP_SUPPORT_NEC_PROTOCOL 1 #endif #if IRMP_SUPPORT_NEC16_PROTOCOL == 1 && IRMP_SUPPORT_NEC_PROTOCOL == 0 -#warning NEC16 protocol needs also NEC protocol, NEC protocol enabled -#undef IRMP_SUPPORT_NEC_PROTOCOL -#define IRMP_SUPPORT_NEC_PROTOCOL 1 +# warning NEC16 protocol needs also NEC protocol, NEC protocol enabled +# undef IRMP_SUPPORT_NEC_PROTOCOL +# define IRMP_SUPPORT_NEC_PROTOCOL 1 #endif #if IRMP_SUPPORT_NEC42_PROTOCOL == 1 && IRMP_SUPPORT_NEC_PROTOCOL == 0 -#warning NEC42 protocol needs also NEC protocol, NEC protocol enabled -#undef IRMP_SUPPORT_NEC_PROTOCOL -#define IRMP_SUPPORT_NEC_PROTOCOL 1 +# warning NEC42 protocol needs also NEC protocol, NEC protocol enabled +# undef IRMP_SUPPORT_NEC_PROTOCOL +# define IRMP_SUPPORT_NEC_PROTOCOL 1 #endif #if F_INTERRUPTS > 20000