summaryrefslogtreecommitdiff
path: root/multiplexer.h
diff options
context:
space:
mode:
Diffstat (limited to 'multiplexer.h')
-rw-r--r--multiplexer.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/multiplexer.h b/multiplexer.h
index d7f7aee..0b6cdce 100644
--- a/multiplexer.h
+++ b/multiplexer.h
@@ -56,7 +56,7 @@ volatile unsigned *gpio;
#define GPIO_SET *(gpio+7) // sets bits which are 1 ignores bits which are 0
#define GPIO_CLR *(gpio+10) // clears bits which are 1 ignores bits which are 0
-#define GPIO_ALTER(a) *(gpio+(a==0?10:7)) // alters (a==0: clear, else: set) bits which are 1 ignores bits which are 0
+#define GPIO_ALTER(a) *(gpio+((a)==0?10:7)) // alters (a==0: clear, else: set) bits which are 1 ignores bits which are 0
#define GET_GPIO(g) (*(gpio+13)&(1<<g)) // 0 if LOW, (1<<g) if HIGH