mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-03-28 19:20:54 +00:00
assert that we wait at least as long as requested with embedded timer
This commit is contained in:
parent
5dc81bdaad
commit
b7341302a0
@ -92,7 +92,8 @@ static void embedded_set_timer(timer_source_t *ts, uint32_t timeout_in_ms){
|
||||
#ifdef HAVE_TICK
|
||||
uint32_t ticks = embedded_ticks_for_ms(timeout_in_ms);
|
||||
if (ticks == 0) ticks++;
|
||||
ts->timeout = system_ticks + ticks;
|
||||
// time until next tick is < hal_tick_get_tick_period_in_ms() and we don't know, so we add one
|
||||
ts->timeout = system_ticks + 1 + ticks;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user