avr-libc-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-libc-dev] What about to make 'reti' as a default behaviour?


From: Dmitry K.
Subject: Re: [avr-libc-dev] What about to make 'reti' as a default behaviour?
Date: Tue, 18 Dec 2007 08:57:07 +1000
User-agent: KMail/1.5

> > Not always safe - if interrupt is level triggered, and remains
> > active, the main program will be interrupted again and again...
> > This will make the main program run much slower (interrupt and
> > "reti" after every instruction), but work fine otherwise - so
> > it may be difficult to notice the bug (no handler defined for an
> > enabled interrupt).

Marek, thanks for the weighty remark.

Nevertheless, I tend to a variant with returning. Why?
In practice more often the mistake happens such: "no handler
defined for an enabled interrupt". The situation when the user
initiated interruptions which actually it in any way did not
plan to use is improbable. (At least, by the moment of end
of the project). Really, it can not notice delay of the
program, but hardly incomplete functionality of system will be
covered from its look. On the other hand, in this case the user
can localize at once malfunction (a debugging output, LED...).
While in a variant with cycling the user can say only:
"My controller has died."

Dmitry.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]