Yahoo Groups archive

AVR-Chat

Index last updated: 2026-04-28 22:41 UTC

Message

Re: [AVR-Chat] ISR not exiting?

2009-02-24 by David VanHorn

On Tue, Feb 24, 2009 at 4:10 PM, Bill Knight <BillK@rosw.com> wrote:
> David
>   In addition to the other responses, is the following what you
> intended elsewhere?
>
> if ((Raw_Data_Size == 0) && !(GICR & (1 << INT0)))
>
> (note usage of '==' and '&&')
>
> You might also want to revisit the following:
>
> GICR  |= (1<<INT0)|(0<<INT1);
>
> It might be what you want but, for reference is equivalent to
>
> GICR  |= (1<<INT0);
>
> Regards
> -Bill Knight
> R O SoftWare
>
>
> David VanHorn wrote:
>> I'm using GCC.
>>
>> When I comment out the first Debug_Port line, the debug pin does not go high.
>> When I leave it in, the debug pin goes high, but never goes low.
>> Am I missing something special I have to do to exit an ISR?
>>
>> // Timer 0 overflow ISR
>> ISR(TIMER0_OVF_vect)
>> {
>>       Debug_Port |= (1 << Debug_Pin); // High
>>
>>       // Dec to zero timer
>>       if (LCD_Timer > 0)
>>       {
>>       LCD_Timer--;
>>       }
>>
>>       if ((Raw_Data_Size = 0) & !(GICR & (1<< INT0))) //
>>       // If the summer is finished, and sampling is disabled
>>       {// enable sampling
>>               GICR  |= (1<<INT0)|(0<<INT1);   // Enable eampling
>>               Raw_Edge_Flag = 0;                              // Looking for the start of a pulse
>>       }
>>
>>       Debug_Port |= (0 << Debug_Pin);         // Low
>> }
>>
>
>
>
> ------------------------------------
>
> Yahoo! Groups Links
>
>
>
>



-- 

"The very powerful and the very stupid have one thing in common. Instead of
altering their views to fit the facts, they alter the facts to fit their
views... which can be very uncomfortable if you happen to be one of the
facts that needs altering." Doctor Who, Face of Evil

Attachments

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.