Преглед на файлове

Fix watch dog timeout

Addressing issue  https://github.com/ZuluSCSI/ZuluSCSI-firmware/issues/350

When implementing a dynamic watchdog setup, a fixed alarm number was
passed instead of the dynamic one. This fixes the issue for
the RP2040 targets. The Earl E Philhower PlatoformIO framework
doesn't use mbed so error reporting hasn't been fully implemented yet.
Morio преди 1 година
родител
ревизия
ef5a66806d
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      lib/BlueSCSI_platform_RP2040/BlueSCSI_platform.cpp

+ 1 - 1
lib/BlueSCSI_platform_RP2040/BlueSCSI_platform.cpp

@@ -607,7 +607,7 @@ static void watchdog_callback(unsigned alarm_num)
         }
     }
 
-    hardware_alarm_set_target(3, delayed_by_ms(get_absolute_time(), 1000));
+    hardware_alarm_set_target(alarm_num, delayed_by_ms(get_absolute_time(), 1000));
 }
 
 // This function can be used to periodically reset watchdog timer for crash handling.