adafruit / Adafruit_SoftServo

A lightweight software servo library, designed for Trinket/Gemma but good for other Arduino-compats
Other
22 stars 13 forks source link

TIMSK in examples/TrinketKnob #4

Open jsilence opened 7 years ago

jsilence commented 7 years ago

In the example sketch, should'nt TIMSK be TIMSK0 at line 37?

At least my Arduino IDE complains about the former and accepts the latter.

curlyz commented 7 years ago

it can be anything based on your MCU. For example, Atmega8A has different timer than Atmega328, and each kind have 3 timers with some different in name. I suggest you should read "Timer on Atmega" by Qeewiki

ArJayTee commented 6 years ago

Thank you for bringing this up, it helped me figure out the error I was getting with the exact same line.

TaterTot24 commented 1 year ago

I am getting an error with using the "TIMSK" as well. I am using the Trinket Pro (ATmega328). Changing it to "TIMSK0" can get it to compile, but it is not working correctly. Is the "TIMSK0" the same thing and should work the same? I am just wanting to make sure that is not the issue.