Forum Discussion
Altera_Forum
Honored Contributor
11 years agoI doubt that the timer functions are interrupt-safe.
Also I've not seen any hint of any of the Alera suppplied code being 'high performance'. All I would do is take keep a timestamp of when the last byte was received. When you get a new byte look at how old the partial record is, and discard if old. I don't know if one of the Altera Avalon slaves is a 32bit clock counter (or a 32bit usec counter - which would save the software knowing the clock speed) - but one wouldn't be difficult to write. Probably worth having 4 counters: clocks, usec, ms and sec.