diff options
author | Joel Challis <[email protected]> | 2025-01-19 17:07:11 +0000 |
---|---|---|
committer | GitHub <[email protected]> | 2025-01-19 17:07:11 +0000 |
commit | cedd49c59b5a822b6879485cdd412c7d803ae14a (patch) | |
tree | 6ccccbaf041fdfb9c101ee719a214a573b877f81 /platforms/avr/timer.c | |
parent | a62f9a2ffd71376bc72e6c52eeab0798cdb8b52f (diff) | |
download | qmk_firmware-cedd49c59b5a822b6879485cdd412c7d803ae14a.tar.gz qmk_firmware-cedd49c59b5a822b6879485cdd412c7d803ae14a.zip |
Consolidate timer_elapsed implementations (#24830)
Diffstat (limited to 'platforms/avr/timer.c')
-rw-r--r-- | platforms/avr/timer.c | 28 |
1 files changed, 0 insertions, 28 deletions
diff --git a/platforms/avr/timer.c b/platforms/avr/timer.c index 26ba0e29fa..b2230ad84b 100644 --- a/platforms/avr/timer.c +++ b/platforms/avr/timer.c @@ -125,34 +125,6 @@ inline uint32_t timer_read32(void) { return t; } -/** \brief timer elapsed - * - * FIXME: needs doc - */ -inline uint16_t timer_elapsed(uint16_t last) { - uint32_t t; - - ATOMIC_BLOCK(ATOMIC_RESTORESTATE) { - t = timer_count; - } - - return TIMER_DIFF_16((t & 0xFFFF), last); -} - -/** \brief timer elapsed32 - * - * FIXME: needs doc - */ -inline uint32_t timer_elapsed32(uint32_t last) { - uint32_t t; - - ATOMIC_BLOCK(ATOMIC_RESTORESTATE) { - t = timer_count; - } - - return TIMER_DIFF_32(t, last); -} - // excecuted once per 1ms.(excess for just timer count?) #ifndef __AVR_ATmega32A__ # define TIMER_INTERRUPT_VECTOR TIMER0_COMPA_vect |