This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

How do I disable interrupt (IRQ) on my Atmel SAM7X?

Hi.

How can I simply disable interrupts (IRQ) on my ATSAM7X application?
I simply want to prevent some critical HW-timing from beeing interrupted by "other stuff".
Something like:
...
disable_irq();
"PA1=0" // set 0 to a port
"do some time-consuming instruction to ensure a fixed duration"
"PA1=1" // set 1 to the port
enable_irq()

I tried to include "core_cm3.h" and use NVIC_DisableIRQ(1), but it gave me 30 ERRORS and messages like "...error: #1114: this feature not supported on target architecture/processor".

How can I simply disable/enable IRQ's for my SAM7X (which C-procedures to use)?
I'll appreciate comments to this isse.

Best Regards
Terje Bohler

Parents
  • Thanks again Pier.

    It compiles OK, and the compiler does not give any Warnings either.
    But, a "yellow warning triangle" is shown to the left of the "__asm" statement in the C-code-window, and when my mouse hovers over it, the following text is shown:
    "warning: MS-style inline assembly is not supported".

    Hmmm... It sounds spooky...
    Should I simply disregard this message?
    Do you know what it means?

    Best Regards
    Terje Bohler

Reply
  • Thanks again Pier.

    It compiles OK, and the compiler does not give any Warnings either.
    But, a "yellow warning triangle" is shown to the left of the "__asm" statement in the C-code-window, and when my mouse hovers over it, the following text is shown:
    "warning: MS-style inline assembly is not supported".

    Hmmm... It sounds spooky...
    Should I simply disregard this message?
    Do you know what it means?

    Best Regards
    Terje Bohler

Children
No data