Unphone improvements (#172)
- Debounce nav button presses: This fixes multiple triggers on a single press to navigate back. Otherwise, more than 1 app would often close at the same time. - Nav button respond to release instead of push down, because these buttons aren't super reliable in general. (I might change this in the future after more testing) - Move single buzz earlier in boot phase, so that we can detect silent boot loops.
This commit is contained in:
committed by
GitHub
parent
72230129bb
commit
2bbd44a8b5
@@ -64,24 +64,22 @@ static bool unPhonePowerOn() {
|
||||
|
||||
unPhoneFeatures.printInfo();
|
||||
|
||||
// Vibrate once
|
||||
// Note: Do this before power switching logic, to detect silent boot loops
|
||||
unPhoneFeatures.setVibePower(true);
|
||||
tt::kernel::delayMillis(150);
|
||||
unPhoneFeatures.setVibePower(false);
|
||||
|
||||
// Turn off the device if power switch is on off state,
|
||||
// instead of waiting for the Thread to start and continue booting
|
||||
updatePowerSwitch();
|
||||
startPowerSwitchThread();
|
||||
|
||||
unPhoneFeatures.setBacklightPower(false);
|
||||
|
||||
// Init touch screen GPIOs (used for vibe motor)
|
||||
unPhoneFeatures.setVibePower(false);
|
||||
|
||||
unPhoneFeatures.setIrPower(false);
|
||||
|
||||
// This will be default LOW implicitly, but this makes it explicit
|
||||
unPhoneFeatures.setExpanderPower(false);
|
||||
|
||||
// Vibrate once
|
||||
unPhoneFeatures.setVibePower(true);
|
||||
tt::kernel::delayMillis(150);
|
||||
unPhoneFeatures.setVibePower(false);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user