Minor documentation improvements.
[pub/USBasp.git] / LUFA / Drivers / Board / XMEGA / B1_XPLAINED / Buttons.h
index 3dd1dfe..15ae804 100644 (file)
                #if !defined(__DOXYGEN__)\r
                        static inline void Buttons_Init(void)\r
                        {\r
-                               PORTE_OUTCLR    = (BUTTONS_BUTTON1 | BUTTONS_BUTTON2 | BUTTONS_BUTTON3 | BUTTONS_BUTTON4);\r
+                               PORTE.OUTSET    = (BUTTONS_BUTTON1 | BUTTONS_BUTTON2 | BUTTONS_BUTTON3 | BUTTONS_BUTTON4);\r
 \r
-                               PORTCFG_MPCMASK = (BUTTONS_BUTTON1 | BUTTONS_BUTTON2 | BUTTONS_BUTTON3 | BUTTONS_BUTTON4);\r
-                               PORTE_PIN0CTRL  = PORT_OPC_PULLUP_gc;\r
+                               PORTCFG.MPCMASK = (BUTTONS_BUTTON1 | BUTTONS_BUTTON2 | BUTTONS_BUTTON3 | BUTTONS_BUTTON4);\r
+                               PORTE.PIN0CTRL  = (PORT_INVEN_bm | PORT_OPC_PULLUP_gc);\r
                        }\r
 \r
                        static inline void Buttons_Disable(void)\r
                        {\r
-                               PORTE_OUTCLR    = (BUTTONS_BUTTON1 | BUTTONS_BUTTON2 | BUTTONS_BUTTON3 | BUTTONS_BUTTON4);\r
+                               PORTE.OUTCLR    = (BUTTONS_BUTTON1 | BUTTONS_BUTTON2 | BUTTONS_BUTTON3 | BUTTONS_BUTTON4);\r
 \r
-                               PORTCFG_MPCMASK = (BUTTONS_BUTTON1 | BUTTONS_BUTTON2 | BUTTONS_BUTTON3 | BUTTONS_BUTTON4);\r
-                               PORTE_PIN0CTRL  = 0;\r
+                               PORTCFG.MPCMASK = (BUTTONS_BUTTON1 | BUTTONS_BUTTON2 | BUTTONS_BUTTON3 | BUTTONS_BUTTON4);\r
+                               PORTE.PIN0CTRL  = 0;\r
                        }\r
 \r
                        static inline uint8_t Buttons_GetStatus(void) ATTR_WARN_UNUSED_RESULT;\r
                        static inline uint8_t Buttons_GetStatus(void)\r
                        {\r
-                               return (~PORTE_IN & (BUTTONS_BUTTON1 | BUTTONS_BUTTON2 | BUTTONS_BUTTON3 | BUTTONS_BUTTON4));\r
+                               return (PORTE_IN & (BUTTONS_BUTTON1 | BUTTONS_BUTTON2 | BUTTONS_BUTTON3 | BUTTONS_BUTTON4));\r
                        }\r
                #endif\r
 \r