rp2/cyw43_configport: Implement cyw43_delay_ms as mp_hal_delay_ms.

They do the same thing.

Signed-off-by: Damien George <damien@micropython.org>
This commit is contained in:
Damien George 2023-11-14 16:18:55 +11:00
parent 12ef8a5ba2
commit e182f3862e
1 changed files with 1 additions and 6 deletions

View File

@ -116,12 +116,7 @@ static inline void cyw43_delay_us(uint32_t us) {
}
static inline void cyw43_delay_ms(uint32_t ms) {
uint32_t us = ms * 1000;
int32_t start = mp_hal_ticks_us();
while (mp_hal_ticks_us() - start < us) {
cyw43_yield();
MICROPY_EVENT_POLL_HOOK_FAST;
}
mp_hal_delay_ms(ms);
}
#define CYW43_EVENT_POLL_HOOK MICROPY_EVENT_POLL_HOOK_FAST