BasicMicro - Forums

www.basicmicro.com
It is currently Mon May 21, 2012 8:07 pm

All times are UTC - 8 hours [ DST ]




Post new topic Reply to topic  [ 5 posts ] 
Author Message
 Post subject: Interrupts
PostPosted: Thu May 29, 2003 10:00 am 
Nathan, some questions on Intterupts :

1 - Does ENABLE setup pin direction as input
for the appropriate pin and enable an
internal pullup on that pin ?

2 - Does RESUME re-ENABLE the interrupt ?

3 - In clocks what is the latency to the
interrupt routine from an interrupt ?
Is it variable or fixed and determan-
istic ?

4 - Does one have to DISABLE the interrupt
when first entering the interrupt
service routine ?

Regards, Dana.



Top
  
 
 Post subject: Re: Interrupts
PostPosted: Sun Jun 08, 2003 10:00 am 
Offline
Site Admin
User avatar

Joined: Thu Mar 01, 2001 11:00 am
Posts: 903
Location: Temecula, CA
1. No. Enable only sets the interrupt enable bits.

2. No. If interrupts are disabled by a disable command then you must reenable the interrupt before exiting.

3. The interrupt latency is from 15 to 23 cycles(I beleive). The exact latency range is listed in the Hitachi 3664 hardware manual.

Nathan


_________________
Tech Support
Basic Micro - Robotic Technology Evolved


Top
 Profile  
 
 Post subject: Re: Interrupts
PostPosted: Sun Jun 08, 2003 10:00 am 
Offline
Site Admin
User avatar

Joined: Thu Mar 01, 2001 11:00 am
Posts: 903
Location: Temecula, CA
4. Yes and no. In some situations you may want to be able to handle multiple interrupts even when another interrupt is running. Of course you can only do this so much since ram is limited.

Nathan


_________________
Tech Support
Basic Micro - Robotic Technology Evolved


Top
 Profile  
 
 Post subject: Interrupts
PostPosted: Fri Jul 04, 2003 10:00 pm 
Nathan, using an older board, piggy back board labeled Rev B, 2002.

I tried the following code and interrupt does not happen, vector to routine that is.
And in debugger variable x never shows a value. Note on this board P19 is IRQ3.
Also IRQ0 and IRQ1 are not brought to the proto area, IRQ1 has a pullup on it
on piggyback board, IRQ0 has a R and Diode network connected to it.



;IRQ3 example
x var byte
INPUT P19
PMR1 = 0x80 ;sets P19 as an IRQ3 input
ENABLE IRQ3INT
ONINTERRUPT IRQ3INT,p_ulseP0


x = PMR1
Main:
PAUSE 1
GOTO Main
;
p_ulseP0:
DISABLE IRQ3INT
PULSOUT P0, 1000000
ENABLE IRQ3INT
RESUME


Top
  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

All times are UTC - 8 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group

phpBB SEO