Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

3
  • 2
    you exclude a lot of values if you increment by 100 .... please post the code that reaches max freq Commented May 27, 2019 at 2:19
  • Note that when OCR1A-=100; makes TCNT1 lower than OCR1A you miss the compare match and have to wait a full second for the timer to overflow. Use waveform generation mode 15 instead of 4 (CTC) to avoid this. Commented May 27, 2019 at 8:44
  • Okay, I updated with the code that reaches the full freq. I intend to skip a lot of values in the increment as I am not trying to get every single value. What does the changing to wave generation mode 15 do? Commented May 27, 2019 at 12:36