Wiring Forum
http://wiring.org.co/cgi-bin/yabb/YaBB.pl
Programming Questions & Help >> Syntax >> Interrupt + delays?
http://wiring.org.co/cgi-bin/yabb/YaBB.pl?num=1206935296

Message started by tylerfurtwangler on 03/31/08 at 03:48:16

Title: Interrupt + delays?
Post by tylerfurtwangler on 03/31/08 at 03:48:16
Does anyone know why my program would not function properly when a delay call was put into an interrupt function?  I know this is a very general question, but from my experimentation the program halted on delay(x) calls from within a interrupt function.  any ideas?

Also, does anyone know if interrupts can occur from within an interrupt?  If I wanted to ensure that this does not happen (and they are allowed to interrupt another interrupt), should I detach the interrupt, run code, then re-attach it?  or is this where the noInterrupts and interrupts functions are used?

Thanks,
-Tyler Furtwangler

Title: Re: Interrupt + delays?
Post by worapoht on 03/31/08 at 07:27:05
Wiring had easier way.. if your application not restict to microsecond, the free running timer may help.
on example,
http://wiring.org.co/learning/examples/timer.html

else you need the real TIMER1 interrupt called.

Wiring Forum » Powered by YaBB 2.5 AE!
YaBB Forum Software © 2000-2010. All Rights Reserved.