mirror of
https://xff.cz/git/pinephone-keyboard/
synced 2024-11-09 14:05:43 +01:00
Check that no key is pressed right after setting up IC interrupt and before going to sleep
This commit is contained in:
parent
0899765c07
commit
4b3d885b61
1 changed files with 6 additions and 0 deletions
|
@ -2075,6 +2075,12 @@ void main(void)
|
|||
// pin state against the P6 latch for output
|
||||
p6_changed = 0;
|
||||
P6 = P6;
|
||||
// last check that nothing is pressed currently
|
||||
// if it is, we need to abort the sleep
|
||||
if (keyscan_idle_is_pressed()) {
|
||||
p6_changed = 1;
|
||||
continue;
|
||||
}
|
||||
P0_ICEN = BIT(5);
|
||||
ICIE = 1;
|
||||
|
||||
|
|
Loading…
Reference in a new issue