--- In lpc2000@yahoogroups.com, "sig5534" <sig5534@h...> wrote: > > > Try calling it indirectly: > > > > static void (*pramfunc)(void) = IAP_Test; > > (*pramfunc)(); > > > > Karl Olsen > > Karl, you're close but no cigar yet. I tried it, and the compiler > took it, but when the call gets made I get a PreFetch Abort Excep > error. > > The IAP_Test() func got put in RAM correctly. It is right at > 0x40000000. But the long call methodology is not quite right. > The "sjo" person mentioned something about another long call method. > But I'm not quite sure how he meant to set that up with the pragmas. > > It's almost there. Anymore ideas on making the long call? > > Thanks, Chris. Either use gcc option -mlong-calls on the src file or #pragma long_calls void myfunc(void); #pragma no_long_calls in the header file The objcopy is the simplest and will cause the least problems, especially if you have a *(.text*) defind in your linker script. Regards sjo
Message
Re: How to declare RAM functions in GCC
2005-01-15 by ntfreak2000
Attachments
- No local attachments were found for this message.