浏览代码

Mitigate RPi hosts kernel panic on M997

Work around M997 sometimes causing a kernel panic on the host when sent from a Raspbery Pi, the root cause is currently unknown.
Chris Pepper 4 年前
父节点
当前提交
004bed8a7f
没有帐户链接到提交者的电子邮件
共有 1 个文件被更改,包括 5 次插入1 次删除
  1. 5
    1
      Marlin/src/HAL/LPC1768/HAL.cpp

+ 5
- 1
Marlin/src/HAL/LPC1768/HAL.cpp 查看文件

@@ -63,7 +63,11 @@ int16_t PARSED_PIN_INDEX(const char code, const int16_t dval) {
63 63
   return ind > -1 ? ind : dval;
64 64
 }
65 65
 
66
-void flashFirmware(const int16_t) { NVIC_SystemReset(); }
66
+void flashFirmware(const int16_t) {
67
+  USB_Connect(FALSE);  // USB clear connection
68
+  delay(2000);         // Give OS time to notice
69
+  NVIC_SystemReset();
70
+}
67 71
 
68 72
 void HAL_clear_reset_source(void) {
69 73
   TERN_(USE_WATCHDOG, watchdog_clear_timeout_flag());

正在加载...
取消
保存