but now with
CW7.0, I’m stock without that SDK
function. My question is: how can I set dynamically an ISR in the interrupt
vector?
Thanks,
Bruno
Reply by Corey, Rick●May 16, 20052005-05-16
Hi
Bruno
I'm on CW 6, not 7. Also, we do not use PE except in
little "stub" projects, to produce sample code snippets..
What we
use for the vector table has a name like "vector_isr.ASM", or
"vectors.c" . I forget where we got the first version of vector.ASM - maybe
from stationary, or some sample program. The sample vector.c file came
from Processor Expert.
To
select the ISRs at compile-time, we basically type in the name of the C function
that has "#Pragma interrupt saveall", preceded by an "F", directly into the
vector table. You have to provide a function prototype in
vector_isr.ASM.
Little
bits of sample code are below, from Metrowerks.
Is that
what you were trying to do? Or do you want to change the ISR at
run-time? For that we made the real ISR call a function pointer, and we
change the function pointer at run-time. In the example below,
"FISR_GPIO_Port_D_Interrupt " means "jump to the C function
"ISR_GPIO_Port_D_Interrupt" . That function has "#pragma interrupt
saveall". It calls a function pointer, that we set up at runtime, usually
a different function pointer for each pin on PortD.
; ----------------------------- Stepper Motor ISRs - function
prototypes global FDecoder0HomeOrWatchdogISR global FDecoder1HomeOrWatchdogISR
global
FQTimerISRC0
; JohnB's dispatch function calls ISR_StepperTimerC0
global
FQTimerISRC1
; JohnB's dispatch function calls ISR_StepperTimerC1
global FISR_GPIO_Port_D_Interrupt ; GPIO POrt D IRQ: used for
MoveToSensor, levelSens, TipJam, & DoorOpen in dspGPIO.C
; ----------------------------- FlexCAN ISRs - function
prototypes global
FISR_FlexCanRxTx
; RCorey 07/28/2004 ... there is s a c fucntion "ISR_FlexCanRxTx" global
FISR_FlexCanErrors ;
RCorey 07/28/2004 global
FISR_FlexCanWakeUp ;
RCorey 08/13/2004 global
FISR_FlexCanBusOff ;
RCorey 08/13/2004
-----Original Message----- From: m...@yahoogroups.com
[mailto:m...@yahoogroups.com]On Behalf Of Bruno Tremblay Sent: Monday, May 16, 2005 11:04 AM To:
m...@yahoogroups.com Subject: [motoroladsp] Dynamic interrupt with
CW7.0
Hi,
Again with that question. With the SDK, I was using the function
:
but now with
CW7.0, I'm stock without that SDK function. My question is: how can I set
dynamically an ISR in the interrupt vector?
Thanks,
Bruno
NEW! You can now post a message or
access and search the archives of this group on DSPRelated.com: http://www.dsprelated.com/groups/motoroladsp/1.php
_____________________________________ Note: If you do a simple "reply"
with your email client, only the author of this message will receive your
answer. You need to do a "reply all" if you want your answer to be
distributed to the entire group.
_____________________________________ About this discussion group:
Reply by Liechty Ronald-RAT109●May 20, 20052005-05-20
Hi Bruno,
My apology for the delay in my
response.
This feature
is not supported in Processor Expert.
Allocation of the interrupt, without using a bean for the
peripheral, is
supported by a special bean InterruptVector which allows
you to specify name of
the ISR and generates a name of the IRS into vectors.c
file.
However, the runtime changes of the vector is not directly
supported in this
case as well and you will have to do this within your code
(for example using
an IF condition or using a function pointer variable).
Hope this helps.
Ron
-- Ron
Liechty (MW
Ron)
Ombudsman, Manager FOCUS team
r...@freescale.com
-----Original Message----- From:m...@yahoogroups.com [mailto:m...@yahoogroups.com] On Behalf Of Bruno
Tremblay
Again
with that question. With the SDK, I was using the function
: