From 03d6e165bb0baf9d0093250d3c3c0771290df4d6 Mon Sep 17 00:00:00 2001 From: ofples Date: Fri, 25 Nov 2016 09:17:40 +0200 Subject: Added missing endif for ifdef __AVR_ATmega32U4__ and removed the unnecessary one at the end of the file --- quantum/config_common.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'quantum/config_common.h') diff --git a/quantum/config_common.h b/quantum/config_common.h index 8ed5f4a106..443473292d 100644 --- a/quantum/config_common.h +++ b/quantum/config_common.h @@ -76,6 +76,7 @@ } while(0) # else # error "USART configuration is needed." +# endif #endif // I'm fairly sure these aren't needed, but oh well - Jack @@ -125,4 +126,3 @@ #endif -#endif -- cgit v1.2.3 From 0c9d66eb59add717397ba83d508577073412ce86 Mon Sep 17 00:00:00 2001 From: ofples Date: Fri, 25 Nov 2016 09:20:41 +0200 Subject: Removed comment --- quantum/config_common.h | 2 -- 1 file changed, 2 deletions(-) (limited to 'quantum/config_common.h') diff --git a/quantum/config_common.h b/quantum/config_common.h index 443473292d..6b525fe1c6 100644 --- a/quantum/config_common.h +++ b/quantum/config_common.h @@ -79,8 +79,6 @@ # endif #endif -// I'm fairly sure these aren't needed, but oh well - Jack - /* * PS/2 Interrupt configuration */ -- cgit v1.2.3 From de1df639535817e17f1c01f07e7a629cec478526 Mon Sep 17 00:00:00 2001 From: Priyadi Iman Nurcahyo Date: Sat, 26 Nov 2016 13:55:41 +0700 Subject: PS2 pins configuration belongs to each keyboards config.h Each keyboard might have different pin configuration. And keeping this here will trigger redefinition warning on keyboards that have PS2 defines. --- quantum/config_common.h | 46 ---------------------------------------------- 1 file changed, 46 deletions(-) (limited to 'quantum/config_common.h') diff --git a/quantum/config_common.h b/quantum/config_common.h index 6b525fe1c6..21960f1a05 100644 --- a/quantum/config_common.h +++ b/quantum/config_common.h @@ -78,49 +78,3 @@ # error "USART configuration is needed." # endif #endif - -/* - * PS/2 Interrupt configuration - */ -#ifdef PS2_USE_INT -/* uses INT1 for clock line(ATMega32U4) */ -#define PS2_CLOCK_PORT PORTD -#define PS2_CLOCK_PIN PIND -#define PS2_CLOCK_DDR DDRD -#define PS2_CLOCK_BIT 1 - -#define PS2_DATA_PORT PORTD -#define PS2_DATA_PIN PIND -#define PS2_DATA_DDR DDRD -#define PS2_DATA_BIT 0 - -#define PS2_INT_INIT() do { \ - EICRA |= ((1< Date: Sat, 26 Nov 2016 14:02:38 +0700 Subject: Fix unterminated ifndef --- quantum/config_common.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'quantum/config_common.h') diff --git a/quantum/config_common.h b/quantum/config_common.h index 21960f1a05..4d3939dae1 100644 --- a/quantum/config_common.h +++ b/quantum/config_common.h @@ -78,3 +78,5 @@ # error "USART configuration is needed." # endif #endif + +#endif \ No newline at end of file -- cgit v1.2.3 From d9d67e7b7686fdcbc7269a76d2a54c42325bdd03 Mon Sep 17 00:00:00 2001 From: Priyadi Iman Nurcahyo Date: Sat, 26 Nov 2016 15:26:02 +0700 Subject: add macro error when a required define is missing --- quantum/config_common.h | 118 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 118 insertions(+) (limited to 'quantum/config_common.h') diff --git a/quantum/config_common.h b/quantum/config_common.h index 4d3939dae1..0a2dba78ff 100644 --- a/quantum/config_common.h +++ b/quantum/config_common.h @@ -79,4 +79,122 @@ # endif #endif +#ifdef PS2_USE_BUSYWAIT +# ifndef PS2_CLOCK_PORT +# error "PS2_CLOCK_PORT has to be defined" +# endif +# ifndef PS2_CLOCK_PIN +# error "PS2_CLOCK_PIN has to be defined" +# endif +# ifndef PS2_CLOCK_DDR +# error "PS2_CLOCK_DDR has to be defined" +# endif +# ifndef PS2_CLOCK_BIT +# error "PS2_CLOCK_BIT has to be defined" +# endif +# ifndef PS2_DATA_PORT +# error "PS2_DATA_PORT has to be defined" +# endif +# ifndef PS2_DATA_PIN +# error "PS2_DATA_PIN has to be defined" +# endif +# ifndef PS2_DATA_DDR +# error "PS2_DATA_DDR has to be defined" +# endif +# ifndef PS2_DATA_BIT +# error "PS2_DATA_BIT has to be defined" +# endif +#endif + +#ifdef PS2_USE_INT +# ifndef PS2_CLOCK_PORT +# error "PS2_CLOCK_PORT has to be defined" +# endif +# ifndef PS2_CLOCK_PIN +# error "PS2_CLOCK_PIN has to be defined" +# endif +# ifndef PS2_CLOCK_DDR +# error "PS2_CLOCK_DDR has to be defined" +# endif +# ifndef PS2_CLOCK_BIT +# error "PS2_CLOCK_BIT has to be defined" +# endif +# ifndef PS2_DATA_PORT +# error "PS2_DATA_PORT has to be defined" +# endif +# ifndef PS2_DATA_PIN +# error "PS2_DATA_PIN has to be defined" +# endif +# ifndef PS2_DATA_DDR +# error "PS2_DATA_DDR has to be defined" +# endif +# ifndef PS2_DATA_BIT +# error "PS2_DATA_BIT has to be defined" +# endif +# ifndef PS2_INT_INIT +# error "PS2_INT_INIT has to be defined" +# endif +# ifndef PS2_INT_ON +# error "PS2_INT_ON has to be defined" +# endif +# ifndef PS2_INT_OFF +# error "PS2_INT_OFF has to be defined" +# endif +# ifndef PS2_INT_VECT +# error "PS2_INT_VECT has to be defined" +# endif +#endif + +#ifdef PS2_USE_USART +# ifndef PS2_CLOCK_PORT +# error "PS2_CLOCK_PORT has to be defined" +# endif +# ifndef PS2_CLOCK_PIN +# error "PS2_CLOCK_PIN has to be defined" +# endif +# ifndef PS2_CLOCK_DDR +# error "PS2_CLOCK_DDR has to be defined" +# endif +# ifndef PS2_CLOCK_BIT +# error "PS2_CLOCK_BIT has to be defined" +# endif +# ifndef PS2_DATA_PORT +# error "PS2_DATA_PORT has to be defined" +# endif +# ifndef PS2_DATA_PIN +# error "PS2_DATA_PIN has to be defined" +# endif +# ifndef PS2_DATA_DDR +# error "PS2_DATA_DDR has to be defined" +# endif +# ifndef PS2_DATA_BIT +# error "PS2_DATA_BIT has to be defined" +# endif +# ifndef PS2_USART_INIT +# error "PS2_USART_INIT has to be defined" +# endif +# ifndef PS2_USART_RX_INT_ON +# error "PS2_USART_RX_INT_ON has to be defined" +# endif +# ifndef PS2_USART_RX_POLL_ON +# error "PS2_USART_RX_POLL_ON has to be defined" +# endif +# ifndef PS2_USART_OFF +# error "PS2_USART_OFF has to be defined" +# endif +# ifndef PS2_USART_RX_READY +# error "PS2_USART_RX_READY has to be defined" +# endif +# ifndef PS2_USART_RX_DATA +# error "PS2_USART_RX_DATA has to be defined" +# endif +# ifndef PS2_USART_ERROR +# error "PS2_USART_ERROR has to be defined" +# endif +# ifndef PS2_USART_RX_VECT +# error "PS2_USART_RX_VECT has to be defined" +# endif +#endif + + #endif \ No newline at end of file -- cgit v1.2.3 From f2214ce1cb6cfe7a0efabe870a2c00fb8451ee80 Mon Sep 17 00:00:00 2001 From: Priyadi Iman Nurcahyo Date: Sat, 26 Nov 2016 15:57:48 +0700 Subject: remove define checks. didn't work because of include ordering. --- quantum/config_common.h | 118 ------------------------------------------------ 1 file changed, 118 deletions(-) (limited to 'quantum/config_common.h') diff --git a/quantum/config_common.h b/quantum/config_common.h index 0a2dba78ff..4d3939dae1 100644 --- a/quantum/config_common.h +++ b/quantum/config_common.h @@ -79,122 +79,4 @@ # endif #endif -#ifdef PS2_USE_BUSYWAIT -# ifndef PS2_CLOCK_PORT -# error "PS2_CLOCK_PORT has to be defined" -# endif -# ifndef PS2_CLOCK_PIN -# error "PS2_CLOCK_PIN has to be defined" -# endif -# ifndef PS2_CLOCK_DDR -# error "PS2_CLOCK_DDR has to be defined" -# endif -# ifndef PS2_CLOCK_BIT -# error "PS2_CLOCK_BIT has to be defined" -# endif -# ifndef PS2_DATA_PORT -# error "PS2_DATA_PORT has to be defined" -# endif -# ifndef PS2_DATA_PIN -# error "PS2_DATA_PIN has to be defined" -# endif -# ifndef PS2_DATA_DDR -# error "PS2_DATA_DDR has to be defined" -# endif -# ifndef PS2_DATA_BIT -# error "PS2_DATA_BIT has to be defined" -# endif -#endif - -#ifdef PS2_USE_INT -# ifndef PS2_CLOCK_PORT -# error "PS2_CLOCK_PORT has to be defined" -# endif -# ifndef PS2_CLOCK_PIN -# error "PS2_CLOCK_PIN has to be defined" -# endif -# ifndef PS2_CLOCK_DDR -# error "PS2_CLOCK_DDR has to be defined" -# endif -# ifndef PS2_CLOCK_BIT -# error "PS2_CLOCK_BIT has to be defined" -# endif -# ifndef PS2_DATA_PORT -# error "PS2_DATA_PORT has to be defined" -# endif -# ifndef PS2_DATA_PIN -# error "PS2_DATA_PIN has to be defined" -# endif -# ifndef PS2_DATA_DDR -# error "PS2_DATA_DDR has to be defined" -# endif -# ifndef PS2_DATA_BIT -# error "PS2_DATA_BIT has to be defined" -# endif -# ifndef PS2_INT_INIT -# error "PS2_INT_INIT has to be defined" -# endif -# ifndef PS2_INT_ON -# error "PS2_INT_ON has to be defined" -# endif -# ifndef PS2_INT_OFF -# error "PS2_INT_OFF has to be defined" -# endif -# ifndef PS2_INT_VECT -# error "PS2_INT_VECT has to be defined" -# endif -#endif - -#ifdef PS2_USE_USART -# ifndef PS2_CLOCK_PORT -# error "PS2_CLOCK_PORT has to be defined" -# endif -# ifndef PS2_CLOCK_PIN -# error "PS2_CLOCK_PIN has to be defined" -# endif -# ifndef PS2_CLOCK_DDR -# error "PS2_CLOCK_DDR has to be defined" -# endif -# ifndef PS2_CLOCK_BIT -# error "PS2_CLOCK_BIT has to be defined" -# endif -# ifndef PS2_DATA_PORT -# error "PS2_DATA_PORT has to be defined" -# endif -# ifndef PS2_DATA_PIN -# error "PS2_DATA_PIN has to be defined" -# endif -# ifndef PS2_DATA_DDR -# error "PS2_DATA_DDR has to be defined" -# endif -# ifndef PS2_DATA_BIT -# error "PS2_DATA_BIT has to be defined" -# endif -# ifndef PS2_USART_INIT -# error "PS2_USART_INIT has to be defined" -# endif -# ifndef PS2_USART_RX_INT_ON -# error "PS2_USART_RX_INT_ON has to be defined" -# endif -# ifndef PS2_USART_RX_POLL_ON -# error "PS2_USART_RX_POLL_ON has to be defined" -# endif -# ifndef PS2_USART_OFF -# error "PS2_USART_OFF has to be defined" -# endif -# ifndef PS2_USART_RX_READY -# error "PS2_USART_RX_READY has to be defined" -# endif -# ifndef PS2_USART_RX_DATA -# error "PS2_USART_RX_DATA has to be defined" -# endif -# ifndef PS2_USART_ERROR -# error "PS2_USART_ERROR has to be defined" -# endif -# ifndef PS2_USART_RX_VECT -# error "PS2_USART_RX_VECT has to be defined" -# endif -#endif - - #endif \ No newline at end of file -- cgit v1.2.3