>>...
 >> The highest priority ISR (irq 3) NEEDS to run at a very fixed rate
 >> so that the ISR that grabs the data from the A/D converter FIFO
 >> does not overflow causing loss of data.  This ISR gets called
 >> every 1.6 msec and it takes approx.  550 usec to pull the data
 >> off.
 >> 
 >> The lower priority ISR (irq 4) is an RS485 serial interface that
 >> is used at a lower rate (every 30 Hz, 33.33 msec).  However, when
 >> it is time for this ISR to send it's 6 bytes of info it takes
 >> approx. 600 usec to do so.
 >> 
 >> What I expected to see on the o-scope because of the priorities of
 >> the IRQ's is that the lower priority ISR would be preempted when
 >> the higher priority ISR needed service.  BUT this DOES NOT happen
 >> and I lose data !!!

Warning, novice at the keyboard... :-)

Are interrupts disabled while in the ISR?  I would suspect they might
be.  If so, the fact that there are other higher priority interrupts
pending doesn't get noticed.  (Unlike the PDP11 which had several
levels of interrupt disabling...)

Could you make the serial interface service be an RT thread that is
normally stopped?  Then the IRQ4 ISR only starts that thread and
exits.  The thread would be interruptible.  (One hopes that it doesn't
get interrupted by another IRQ4 interrupt -- you could test for that
to verify this.)

   paul

-- [rtl] ---
To unsubscribe:
echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR
echo "unsubscribe rtl <Your_email>" | mail [EMAIL PROTECTED]
---
For more information on Real-Time Linux see:
http://www.rtlinux.org/rtlinux/

Reply via email to