Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: BLE_API mbed-dev nRF51822
Diff: main.cpp
- Revision:
- 47:5bf2ae8cc710
- Parent:
- 45:f4be69c936f6
- Child:
- 48:d6938de02f62
--- a/main.cpp Sun Aug 28 16:25:26 2016 +0000
+++ b/main.cpp Mon Aug 29 12:38:32 2016 +0000
@@ -225,7 +225,7 @@
if (changed & (1<<row)) {
bool pressed = keysCurr[col] & (1<<row);
// DEBUG_KEYEVENT("changed: col=%d, row=%d / pressed=%d\r\n", col, row, pressed);
- keymap.execute(col, row, pressed);
+ keymap.execute(row, col, pressed);
}
}
}
@@ -251,10 +251,9 @@
if (queue) HIDController::queueCurrentReportData();
- // wait_ms(5); is busy loop
- // use timer1 to use wait 5ms
+ // use timer to use wait 5ms
+ keyIntervalInterrupt = false;
timeout.attach_us(wakeupKeyIntervalSleep, 5000);
- keyIntervalInterrupt = false;
while (!keyIntervalInterrupt) HIDController::waitForEvent();
}
} else {