Horus power loop fixed if power button is held pressed.
This commit is contained in:
+1
-1
@@ -311,7 +311,7 @@
|
||||
#define cli()
|
||||
#define sei()
|
||||
extern void boardInit();
|
||||
#if defined(PCBTARANIS)
|
||||
#if defined(PCBTARANIS) or defined(PCBHORUS)
|
||||
extern void boardOff();
|
||||
#else
|
||||
#define boardOff() pwrOff();
|
||||
|
||||
@@ -167,7 +167,20 @@ void boardInit()
|
||||
|
||||
ledBlue();
|
||||
}
|
||||
#endif
|
||||
|
||||
void boardOff()
|
||||
{
|
||||
BACKLIGHT_OFF();
|
||||
|
||||
while (pwrPressed()) {
|
||||
wdt_reset();
|
||||
}
|
||||
|
||||
SysTick->CTRL = 0; // turn off systick
|
||||
pwrOff();
|
||||
}
|
||||
|
||||
#endif // #if !defined(SIMU)
|
||||
|
||||
#if defined(USB_JOYSTICK) && !defined(SIMU)
|
||||
extern USB_OTG_CORE_HANDLE USB_OTG_dev;
|
||||
|
||||
Reference in New Issue
Block a user