none
WEC700, Interrupt latency issue. RRS feed

  • Question

  • Hi,

    I am using iMX51 EVK based board and the BSP provided by Freescale.

    I have configured one of the GPIOs for triggering an interrupt on the rising edge.

    To check the Interrupt Latency, from my IST that services the event mapped to this IRQ, I am toggling another port pin as the first instruction in my IST.

    On a oscilloscope I can see that it take ~48 micro-seconds between the rising edge interrupt signal and the state change on the test pin.

    I find it strange as I was expecting the latency to be in order of 10s of microseconds. 

    Is 48 micro-seconds latency normal? Or there is something wrong? What could be the possible causes that I need to check? The iMX clock configuration is one thing that I know and am checking, anything else apart from that?

    Thanks

    Wednesday, October 9, 2013 1:52 PM

All replies

  • What is the interrupt priority in your ISR?  That is how many interrupts are processed before this one when several interrupts hit at the same time?

    What is the thread priority of your IST?

    How much jitter do you have?  Is always 48 microseconds give or take a few microseconds?


    Bruce Eitman (eMVP)
    Senior Engineer
    Bruce.Eitman AT Eurotech DOT com
    My BLOG http://geekswithblogs.net/bruceeitman

    Eurotech Inc.
    www.Eurotech.com

    Wednesday, October 9, 2013 3:04 PM
    Moderator
  • Hi Bruce,

    Thanks for your reply.

    I found out the reason for such a high latency value. 

    I had my device connected to my PC using a remote terminal utility, cerhost.exe.

    This would have led to higher ethernet traffic and subsequently more interrupts from the ethernet controller, or in addition to it some more components that I am not aware of.

    When I disconnect the remote terminal host the interrupt latency is 16 micro-seconds max, and 9.5 micro-seconds minimum. Average latency is around 12 micro-seconds.

    For my application this latency would be acceptable, but for Windows Embedded Compact 7 is this latency normal?

    Thanks

    Thursday, October 10, 2013 12:59 PM
  • I the latency normal?  This is Windows CE, so there is no normal.  Every system is different.

    When it comes to interrupt handling it takes a System Engineer to evaluate the importance of interrupts and threads.  Then set priorities according to the needs of the system.

    If your GPIO interrupt is more important than Ethernet, you should set the interrupt priority and IST thread priority higher than Ethernet.


    Bruce Eitman (eMVP)
    Senior Engineer
    Bruce.Eitman AT Eurotech DOT com
    My BLOG http://geekswithblogs.net/bruceeitman

    Eurotech Inc.
    www.Eurotech.com

    Thursday, October 10, 2013 1:52 PM
    Moderator