The HAL_Delay in the ST HAL library works in milliseconds.CHAL_Delay(2); // 实际延迟3ms HAL_Delay(1); // 实际延迟2ms HAL_Delay(0); // 实际延迟1ms That's right—the actual delay is always 1 ms longer than the value you pass in.Previously, an Example noticed and handled this issue.But since I rarely use HAL_Delay, I forgot about it again today. Writing it down here in case I need it in a couple of days.
HAL_Delay in the ST HAL Library
The HAL_Delay in the ST HAL library works in milliseconds.
That's right—the actual delay is always 1 ms longer than the value you pass in.
Previously, an Example noticed and handled this issue.
But since I rarely use HAL_Delay, I forgot about it again today. Writing it down here in case I need it in a couple of days.