I need a way to set a timer interrupt on an Uno R3. That is, after x second/milliseconds/whatever I need an interrupt to trigger. I've done a forum search, and there are posts that seem to make reference to timer interrupts, but I can't find the code to do it.
The Delay function won't work in my context (basically my code will be running along receiving inputs. If it doesn't receive an input after x time expires, I need to output something and then start receiving inputs again).
There are also libraries to help set up timers. Usually though, it only requires a few lines of code, if you are comfortable dealing directly with the microcontroller's registers. The Atmel datasheet is also an important document to have.
I wonder if it would be sufficient to use millis() with the technique in the Blink Without Delay example sketch and in the demo several things at a time.
That is how I would implement a timeout. It would be much easier to debug and to modify.