ATXMEGA32E5 issue

Go To Last Post
2 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi everyone, I'm working with ATXMEGA32E5, this MCU offer the possibility to setup 2 different timers T4/T5, T4 has 2 channels [A, B], while T5 has 4 channels [A, B, C, D]. I'm using T4 as PWM output while T5 is used as 1ms overflow interrupt.

So my question is: Can I setup 1 channel of T5 (channel C for example) as 500us overflow interrupt? I mean, si possibile to define different period for different channels in a single timer?

Thanks everyone.UC Browser SHAREit Appvn

Last Edited: Tue. Nov 5, 2019 - 02:41 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 1

Just set the timer to 500us and do the 500us stuff on every "tick" and the 1ms stuff on every second "tick".

 

(in general set the timer rate to the lowest common denominator of all tasks and then keep /N counters to schedule the various tasks that derive from this).