<html>
<head>
</head>
<body>
Within the ISR I am doing the following:<br>
<br>
Reading a 16 bit word from an I/O address<br>
Decoding and adding that word onto a queue that is emptied out by a running
task<br>
Checking a second queue for data that needs to be transmitted<br>
Transmitting a word to the I/O card.<br>
Setting an event that causes the running task to empty the queue.<br>
<br>
Using this methodology will eventually ensure that the I/O card does not
send data faster that the ISR can accept them.<br>
<br>
I have sentries in place to test if the queue overflows and also if a byte
is missing.<br>
I get no errors at an interrupt spacing of 620 us.  Anything faster than
that I lose bits.<br>
This I/O card is an interface to a MIDI input and output stream, which has
a potential of 3 bytes per ms (31.25kbs), however, most MIDI .  The I/O card
I designed has a 16 byte input buffer so it would be able to slow down the
fasted transmissions. Losing some bytes in this instance is not that big
a deal for my project as I have overflowed MIDI buffers other synthesizers.
 The important thing, however, is that I can already catch and display the
overflow condition within the I/O card, which should be able to spit them
down into the the ISR as fast as it is able.<br>
<br>
Joel Sherrill wrote:<br>
<blockquote type="cite" cite="mid:3C76EA9D.3ABDAA91@OARcorp.com">
  <pre wrap=""><br>Angelo Fraietta wrote:<br></pre>
  <blockquote type="cite">
    <pre wrap="">I worked it out. I did not have the interrupt pin held high for long<br>enough. I am now generating and decoding interrupts every 1 Ms.<br></pre>
    </blockquote>
    <pre wrap=""><!----><br>I am glad you worked it out.  I would expect that you can sustain<br>a fairly high interrupt rate but it always depends on how much<br>processing is required per interrupt in the ISR and what <br>that implies for task processing.  Sure you can do a LOT of <br>interrupts that clear a bit and return but useful work is another<br>matter.  For example, sustaining a high RX rate on a UART is<br>often more than a CPU can do.<br><br>-joel<br><br></pre>
    <blockquote type="cite">
      <pre wrap="">Angelo Fraietta wrote:<br><br></pre>
      <blockquote type="cite">
        <pre wrap="">At what speed can I have interrupts happening in the pc386 bsp running<br>at 16 MHz. I am generating an interrupt with an external<br>microcontroller -- currently every 30 Ms (I was hoping to make it<br>possible every 1 Ms) -- however, the 386 is missing some of the<br>interrupts.  I am attempting to transfer data between the<br>microcontroller an the 386 by using a 16 Bit device driver and using<br>interrupts to synchronize the two processors. Should I be trying to<br>use DMA for data transfer rates of this speed?<br><br></pre>
        </blockquote>
        <pre wrap="">--<br>Angelo Fraietta<br><br>PO Box 859<br>Hamilton NSW 2303<br><br>Home Page<br><br><a class="moz-txt-link-freetext" href="http://www.users.bigpond.com/angelo_f/">http://www.users.bigpond.com/angelo_f/</a><br><br>There are those who seek knowledge for the sake of knowledge - that is CURIOSITY<br>There are those who seek knowledge to be known by others - that is VANITY<br>There are those who seek knowledge in order to serve - that is LOVE<br>    Bernard of Clairvaux (1090 - 1153)<br></pre>
        </blockquote>
        <pre wrap=""><!----><br></pre>
        </blockquote>
        <br>
        <pre class="moz-signature" cols="$mailwrapcol">-- 
Angelo Fraietta

PO Box 859
Hamilton NSW 2303

Home Page


<a class="moz-txt-link-freetext" href="http://www.users.bigpond.com/angelo_f/">http://www.users.bigpond.com/angelo_f/</a>

There are those who seek knowledge for the sake of knowledge - that is CURIOSITY
There are those who seek knowledge to be known by others - that is VANITY
There are those who seek knowledge in order to serve - that is LOVE
    Bernard of Clairvaux (1090 - 1153)</pre>
        <br>
        </body>
        </html>