[Taranis] Cleaner reboot on USB disconnect, longer LCD initialization delay to compensate for the time saved removing USB initialisation
This commit is contained in:
@@ -119,6 +119,12 @@ void USBD_USR_DeviceConnected (void)
|
||||
*/
|
||||
void USBD_USR_DeviceDisconnected (void)
|
||||
{
|
||||
// TODO: Separate the shutdown operations in main() into a shutdown() function in opentx.cpp,
|
||||
// and call that before the NVIC_SystemReset()?
|
||||
g_eeGeneral.unexpectedShutdown = 0;
|
||||
eeDirty(EE_GENERAL);
|
||||
eeCheck(true);
|
||||
|
||||
NVIC_SystemReset();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user