浏览代码

♻️ Watchdog followup

Followup to 52eefa90e1
Scott Lahteine 2 年前
父节点
当前提交
04d0d9431b
共有 2 个文件被更改,包括 5 次插入5 次删除
  1. 4
    4
      Marlin/src/HAL/STM32/msc_sd.cpp
  2. 1
    1
      Marlin/src/HAL/shared/cpu_exception/exception_arm.cpp

+ 4
- 4
Marlin/src/HAL/STM32/msc_sd.cpp 查看文件

@@ -57,7 +57,7 @@ public:
57 57
     auto sd2card = diskIODriver();
58 58
     // single block
59 59
     if (blkLen == 1) {
60
-      watchdog_refresh();
60
+      hal.watchdog_refresh();
61 61
       sd2card->writeBlock(blkAddr, pBuf);
62 62
       return true;
63 63
     }
@@ -65,7 +65,7 @@ public:
65 65
     // multi block optimization
66 66
     sd2card->writeStart(blkAddr, blkLen);
67 67
     while (blkLen--) {
68
-      watchdog_refresh();
68
+      hal.watchdog_refresh();
69 69
       sd2card->writeData(pBuf);
70 70
       pBuf += BLOCK_SIZE;
71 71
     }
@@ -77,7 +77,7 @@ public:
77 77
     auto sd2card = diskIODriver();
78 78
     // single block
79 79
     if (blkLen == 1) {
80
-      watchdog_refresh();
80
+      hal.watchdog_refresh();
81 81
       sd2card->readBlock(blkAddr, pBuf);
82 82
       return true;
83 83
     }
@@ -85,7 +85,7 @@ public:
85 85
     // multi block optimization
86 86
     sd2card->readStart(blkAddr);
87 87
     while (blkLen--) {
88
-      watchdog_refresh();
88
+      hal.watchdog_refresh();
89 89
       sd2card->readData(pBuf);
90 90
       pBuf += BLOCK_SIZE;
91 91
     }

+ 1
- 1
Marlin/src/HAL/shared/cpu_exception/exception_arm.cpp 查看文件

@@ -221,7 +221,7 @@ bool resume_from_fault() {
221 221
   // So we'll just need to refresh the watchdog for a while and then stop for the system to reboot
222 222
   uint32_t last = start;
223 223
   while (PENDING(last, end)) {
224
-    watchdog_refresh();
224
+    hal.watchdog_refresh();
225 225
     while (millis() == last) { /* nada */ }
226 226
     last = millis();
227 227
     MinSerial::TX('.');

正在加载...
取消
保存