summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Sulfrian <alexander@sulfrian.net>2011-11-18 21:56:34 +0100
committerAlexander Sulfrian <alexander@sulfrian.net>2011-11-18 21:56:34 +0100
commit96c740e045fd516a539b821ec82d10007b533bd8 (patch)
tree41c3142ad1ecbd2841c1c8f0d88c76e5004a4e22
parentcf13ba96300dcc98089c2272ed40aefdb54ca13f (diff)
downloadonkyo-ri-96c740e045fd516a539b821ec82d10007b533bd8.tar.gz
onkyo-ri-96c740e045fd516a539b821ec82d10007b533bd8.tar.xz
onkyo-ri-96c740e045fd516a539b821ec82d10007b533bd8.zip
renamed constant for input pin receiving ir
-rw-r--r--onkyo_ri.pde8
1 files changed, 4 insertions, 4 deletions
diff --git a/onkyo_ri.pde b/onkyo_ri.pde
index 17645ec..3fa2808 100644
--- a/onkyo_ri.pde
+++ b/onkyo_ri.pde
@@ -15,8 +15,8 @@ MD = 71808
// Digital pin #2 is the same as Pin D2 see
// http://arduino.cc/en/Hacking/PinMapping168 for the 'raw' pin mapping
-#define IRpin_PIN PINB
-#define IRpin 0
+#define IRread_PIN PINB
+#define IRread 1
#define ARRAY_LEN(array) (sizeof(array)/sizeof((array)[0]))
@@ -42,7 +42,7 @@ void loop(void) {
}
int getPulseLength() {
- bool high = IRpin_PIN & (1 << IRpin);
+ bool high = IRread_PIN & (1 << IRread);
bool check = true;
int length = 0;
@@ -54,7 +54,7 @@ int getPulseLength() {
return -1;
}
- check = IRpin_PIN & (1 << IRpin);
+ check = IRread_PIN & (1 << IRread);
if (! high) {
check = ! check;
}