<div dir="ltr">BTW I changed above code for 4 interrupts</div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jul 28, 2015 at 5:19 PM, Angelo Fraietta <span dir="ltr"><<a href="mailto:newsgroups@smartcontroller.com.au" target="_blank">newsgroups@smartcontroller.com.au</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">I can confirm that the interrupts do work, however, it is on both edges, not just the rising.<div>I wanted to see what sort of performance I could get out of the interrupts by inputting various frequency signals</div><div>I modified the code so 13 would toggle every 8 interrupts. It toggled after four full pulses, therefore it interrupted on both edges (see code at end)</div><div><br></div><div>Also, I found that it took 1.3us to service the interrupt (I measured the time between the edge of interrupt pin and the toggle point of 13). The beagle is supposed to be 1 1GHz machine. Is there any way I can push faster than 1.3us with a setting in RTEMS (eg nanoseconds per tick) or is 1.3us my absolute best?</div><div><br></div><div>Thanks</div><div><br></div><div><span class=""><div><br></div><div>//ISR:</div><div>rtems_isr GPIO1_IRQHandler (rtems_vector_number vector)</div><div>{</div></span><div>  static int i = 0;</div><div><br></div><div>  i++;</div><span class=""><div>  //Toggle other three LEDs here:</div><div>  *(unsigned long *)(GPIO1_ADDR+GPIO_DATAOUT) ^= ((1<<22)| (1<<23) |(1<<24));</div><div>  </div><div>  //Clear interrupt:</div><div>  //Per AM335x technical reference manual, we can read IRQSTATUS,</div><div>  // and then write corresponding bits on IRQSTATUS to clear whichever one was serviced.</div><div>  // in this application it's hard coded to number 12 so I just write that bit.</div><div>  // For some reason writing IRQSTATUS value back to itself doesn't clear the interrupt.</div><div>  unsigned long irqstat = *(unsigned long*)(GPIO1_ADDR + GPIO_IRQSTATUS_1);</div><div>  *(unsigned long*)(GPIO1_ADDR + GPIO_IRQSTATUS_1) = (1<<12);</div><div><br></div></span><div>  // we will toggle every </div><span class=""><div>  //*(unsigned long*)(GPIO1_ADDR + GPIO_IRQSTATUS_1) = irqstat;</div></span><div>  if (!(i % 4))</div><div>    {</div><span class=""><div>    *(unsigned long *)(GPIO1_ADDR+GPIO_DATAOUT) ^= (1<<13);</div><div>    }</div><div>}</div></span></div><div><br></div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jul 28, 2015 at 1:54 AM, Steve B <span dir="ltr"><<a href="mailto:sbattazzo@gmail.com" target="_blank">sbattazzo@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div>Hi Angelo,<br><br></div>Here's a handy diagram that shows which ones are which (found on Google Images):<br><a href="http://cholla.mmto.org/computers/beagle/hardware/pinout1-1024x585.png" target="_blank">http://cholla.mmto.org/computers/beagle/hardware/pinout1-1024x585.png</a><br><br></div>GPIO1_12 is connector P8 pin 12. I think I used the adjacent pin (P8 pin 11, or GPIO1_13) and installed a jumper wire between the two.<br></div><div>I think it says so in my comments too but I know that may not exactly jump out.<span><font color="#888888"><br><br></font></span></div><span><font color="#888888">Steve</font></span><span><br><div><div><br><div><div><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Jul 26, 2015 at 6:38 PM, Angelo Fraietta <span dir="ltr"><<a href="mailto:newsgroups@smartcontroller.com.au" target="_blank">newsgroups@smartcontroller.com.au</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Greetings Steve, I have modified your code so the standard task only toggles one LED and the interrupt on GPIO12 should toggle the other 3. However, IO cannot for the life of me find which pin is GPIO12 so I can test on the hardware. I have posted the code with the mods I made at the bottom of this email<div><br></div><div><a href="http://beagleboard.org/support/bone101" target="_blank">http://beagleboard.org/support/bone101</a><br></div><div><br></div><div>What physical pin should I be toggling to make it work?</div><div><br></div><div>Thanks</div><div><br></div><br></div></blockquote></div></div></div></div></div></div></span></div>
</blockquote></div><br></div>
</div></div></blockquote></div><br></div>