diff --git a/sys/vtimer/vtimer.c b/sys/vtimer/vtimer.c index 8b4e43967bc2ef7b13577c5062a605b31d2361fd..a3f9acb0b107b13aceadd0646140b24c2bf4eab4 100644 --- a/sys/vtimer/vtimer.c +++ b/sys/vtimer/vtimer.c @@ -142,8 +142,8 @@ static int update_shortterm(void) } DEBUG("update_shortterm: Set hwtimer to %" PRIu32 " (now=%lu)\n", next, now); - uint32_t next_ticks = now_ticks + HWTIMER_TICKS(next - now); - hwtimer_id = hwtimer_set_absolute(next_ticks, vtimer_callback, NULL); + unsigned long offset_ticks = (unsigned long)HWTIMER_TICKS(next - now); + hwtimer_id = hwtimer_set(offset_ticks, vtimer_callback, NULL); return 0; }