Browse Source

Improve RPi host kernel panic mitigation

It was still possible to cause a Kernel panic, this additional 500ms delay before disconnect appears to mitigate it completely.
Chris Pepper 3 years ago
parent
commit
5233e66762
No account linked to committer's email address
1 changed files with 2 additions and 1 deletions
  1. 2
    1
      Marlin/src/HAL/LPC1768/HAL.cpp

+ 2
- 1
Marlin/src/HAL/LPC1768/HAL.cpp View File

@@ -64,8 +64,9 @@ int16_t PARSED_PIN_INDEX(const char code, const int16_t dval) {
64 64
 }
65 65
 
66 66
 void flashFirmware(const int16_t) {
67
+  delay(500);          // Give OS time to disconnect
67 68
   USB_Connect(false);  // USB clear connection
68
-  delay(2000);         // Give OS time to notice
69
+  delay(1000);         // Give OS time to notice
69 70
   NVIC_SystemReset();
70 71
 }
71 72
 

Loading…
Cancel
Save