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

Locaion of IRQHandler within C file

I am presently testing the STR710 micro from
STmicroelectronics using KEIL UV3 IDE.
I have discovered from my own code (as well as the sample codes shipped with the compiler. Placing an IRQhandler AFTER the main() function causes the file not compile and showed lots of errors. But when placing
the IRQHandler BEFORE or near the beginning
of the program then it compiled fine.
I have noticed some pre-compile directive
in certain area #pragma userclass (CODE = default) and #pragma userclass (CODE =IRQ)
resided in the c file. However, I had never
be able to come up with a conclusive result
by trying to place the above directives in various area of the file.

My question is what is the RIGHT way to do in term of placing IRQhandler?

void main (void)
{
}

void IRQHandler_one()
{
}

void IRQHanlder_two()
{
}

The above arrangement NOT working

Parents
  • We have re-worked the way ISR routines are defined in the RealView MDK-ARM V3.01 (where we are using the RealView Compiler).

    Please download the current revision MDK-ARM V3.01 and refer to the new version of the MCBSTR7 user's guide that is part of this release.

    Reinhard

Reply
  • We have re-worked the way ISR routines are defined in the RealView MDK-ARM V3.01 (where we are using the RealView Compiler).

    Please download the current revision MDK-ARM V3.01 and refer to the new version of the MCBSTR7 user's guide that is part of this release.

    Reinhard

Children