Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
20 years ago

uC/OS-II ISR questions

Is it true that all ISRs for uC/OS-II must be written in assembly language?

How is an ISR "attached" to a specific interrupt?

Does anybody have an example that I could see (CPU register storage, etc.)?

Thanks.

2 Replies

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    The interrupt entry point must be written in assembly, however this is provided for you with the Nios II port of microC/OS-II. Individual ISR's can be written in C. You can attach to an interrupt using the standard HAL alt_irq_register() function, as described in the Nios II software developer's handbook. In addition, you can look at the HAL device drivers for examples (e.g. the JTAG UART driver).