diff --git a/bsp/stm32f10x/drivers/stm32f1_wdg.c b/bsp/stm32f10x/drivers/stm32f1_wdg.c index fae575abc7d42310f9fddeb91e18897937f2dcf3..a26283fb276b65d246c13c7ea8eae09ddbfaa09a 100644 --- a/bsp/stm32f10x/drivers/stm32f1_wdg.c +++ b/bsp/stm32f10x/drivers/stm32f1_wdg.c @@ -27,7 +27,7 @@ static rt_err_t stm32f1_wdg_control(rt_watchdog_t *wdt, int cmd, void *arg) switch(cmd) { case RT_DEVICE_CTRL_WDT_SET_TIMEOUT: - timeout_ms = (rt_uint32_t) arg; + timeout_ms = *((rt_uint32_t*) arg); IWDG_WriteAccessCmd(IWDG_WriteAccess_Enable); if(timeout_ms >= 13107) {