aboutsummaryrefslogtreecommitdiff
path: root/keyboard
diff options
context:
space:
mode:
authortmk <nobody@nowhere>2014-08-30 15:59:41 +0900
committertmk <nobody@nowhere>2014-08-30 15:59:41 +0900
commit807ed33a9a29ee3c5248226d0e865d0580d7eebc (patch)
tree14e0fdca30b6163b01c868690436225762a5a315 /keyboard
parent28c1bf294c223f3a93ec7ee2420ada7f1e27fba0 (diff)
downloadqmk_firmware-807ed33a9a29ee3c5248226d0e865d0580d7eebc.tar.gz
qmk_firmware-807ed33a9a29ee3c5248226d0e865d0580d7eebc.zip
Fix rn42_linked() to use pullup
Diffstat (limited to 'keyboard')
-rw-r--r--keyboard/hhkb_rn42/rn42/rn42.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/keyboard/hhkb_rn42/rn42/rn42.c b/keyboard/hhkb_rn42/rn42/rn42.c
index 556c61af9..bdffad766 100644
--- a/keyboard/hhkb_rn42/rn42/rn42.c
+++ b/keyboard/hhkb_rn42/rn42/rn42.c
@@ -34,7 +34,7 @@ void rn42_init(void)
34 34
35 // PF6: linked(input without pull-up) 35 // PF6: linked(input without pull-up)
36 DDRF &= ~(1<<6); 36 DDRF &= ~(1<<6);
37 PORTF &= ~(1<<6); 37 PORTF |= (1<<6);
38 38
39 // PF1: RTS(low: allowed to send, high: not allowed) 39 // PF1: RTS(low: allowed to send, high: not allowed)
40 DDRF &= ~(1<<1); 40 DDRF &= ~(1<<1);
@@ -93,7 +93,11 @@ void rn42_cts_lo(void)
93 93
94bool rn42_linked(void) 94bool rn42_linked(void)
95{ 95{
96 return PINF&(1<<6); 96 // RN-42 GPIO2
97 // Hi-Z: Not powered
98 // High: Linked
99 // Low: Connecting
100 return !rn42_rts() && PINF&(1<<6);
97} 101}
98 102
99 103