diff options
| author | Bdale Garbee <bdale@gag.com> | 2018-10-08 17:52:22 -0600 | 
|---|---|---|
| committer | Bdale Garbee <bdale@gag.com> | 2018-10-08 17:52:22 -0600 | 
| commit | 2450e69d3afd3345a6e5f7ca133d929fbdcfdf53 (patch) | |
| tree | c04aa34bdecbf909dbeea8854390364bf140e7ca /src/stm/ao_timer.c | |
| parent | 449ed72371f80f03dcc5dcf66af5c9465e7ed57e (diff) | |
| parent | 5a86ff43a2b4a90dbddc1bba48019626e1b83e10 (diff) | |
Merge branch 'branch-1.8' into debian
Diffstat (limited to 'src/stm/ao_timer.c')
| -rw-r--r-- | src/stm/ao_timer.c | 5 | 
1 files changed, 5 insertions, 0 deletions
diff --git a/src/stm/ao_timer.c b/src/stm/ao_timer.c index 7b526902..9d118b72 100644 --- a/src/stm/ao_timer.c +++ b/src/stm/ao_timer.c @@ -26,6 +26,8 @@  #define HAS_TICK 1  #endif +#if HAS_TICK || defined(AO_TIMER_HOOK) +  #if HAS_TICK  volatile AO_TICK_TYPE ao_tick_count; @@ -34,6 +36,7 @@ ao_time(void)  {  	return ao_tick_count;  } +#endif  #if AO_DATA_ALL  volatile __data uint8_t	ao_data_interval = 1; @@ -44,7 +47,9 @@ void stm_systick_isr(void)  {  	ao_validate_cur_stack();  	if (stm_systick.csr & (1 << STM_SYSTICK_CSR_COUNTFLAG)) { +#if HAS_TICK  		++ao_tick_count; +#endif  #if HAS_TASK_QUEUE  		if (ao_task_alarm_tick && (int16_t) (ao_tick_count - ao_task_alarm_tick) >= 0)  			ao_task_check_alarm((uint16_t) ao_tick_count);  | 
