Reply by Jongsoo Lim October 12, 20042004-10-12
Bruno;

Assuming your ISR is as follows
static void gpio_ISR(){,,,}
Now install ISR using,

int GpioFD;
GpioFD = open(BSP_DEVICE_NAME_GPIO_D, NULL);
archInstallISR(&(pArchInterrupts->MpioD), gpio_ISR);
ioctl(GpioFD, GPIO_SETAS_GPIO, gpioPin(D,0)|gpioPin(D,1)|gpioPin(D,2));
ioctl(GpioFD, GPIO_SETAS_INPUT, gpioPin(D,0)|gpioPin(D,1)|gpioPin(D,2));
ioctl(GpioFD, GPIO_INTERRUPT_DETECTION_ACTIVE_HIGH,
gpioPin(D,0)|gpioPin(D,1)|gpioPin(D,2));
ioctl(GpioFD, GPIO_INTERRUPT_ENABLE, gpioPin(D,0)|gpioPin(D,1)|gpioPin(D,2));
archEnableInt();

That's all.
If one of three pins goes up, then interrupt will be triggered.

JS

Jongsoo Lim
Design Eng
Quantum Controls Inc.
1691 Lake Drive West, Chanhassen MN 55317
> -----Original Message-----
> From: Bruno Tremblay [SMTP:]
> Sent: Tuesday, October 12, 2004 1:37 PM
> To:
> Subject: [motoroladsp] Interrupt on a gpio state change > Hi,
>
> I want to use two GPIO pin as interrupt in my application. Since I
didn't
> found any information on how to do it with the SDK, I must write and find a
> way to call an ISR on a pin change. For now, I know how to set the GPIO
> registers and write my ISR. But I don't how to call the ISR. If there's a
> way with the SDK can some one guide my on where can I find this information?
> And what other way can I use?
>
> Thanks >
> -------
> Bruno Tremblay, Ing/Eng
> Gentec Inc.
> Automatisme et Contre/Automation and Control
> 2625 Dalton, Sainte-Foy
> Quec, Canada G1P 3S9
> email:
> web : www.gentec.ca
> ------- >
>
> _____________________________________
> 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:
>
> To Join:
>
> To Post:
>
> To Leave:
>
> Archives: <http://www.yahoogroups.com/group/motoroladsp>
>
> More Groups: <http://www.dsprelated.com/groups.php3 > click here
<http://us.ard.yahoo.com/SIG9btaic5/M)4855.5468653.6549235.3001176/D=groups\
/S05771855:HM/EXP97692986/A#76776/R=0/SIGldm1jvc/*http://promotions.y\
ahoo.com/ydomains2004/index.html>
>
<http://us.adserver.yahoo.com/l?M)4855.5468653.6549235.3001176/D=groups/S=:HM/\
A#76776/randS4167898>
>
> _____
>
> >.
>



Reply by Bruno Tremblay October 12, 20042004-10-12

Hi,

I want to use two GPIO pin as interrupt in my application. Since I didn't
found any information on how to do it with the SDK, I must write and find a
way to call an ISR on a pin change. For now, I know how to set the GPIO
registers and write my ISR. But I don't how to call the ISR. If there's a
way with the SDK can some one guide my on where can I find this information?
And what other way can I use?

Thanks
-------
Bruno Tremblay, Ing/Eng
Gentec Inc.
Automatisme et Contre/Automation and Control
2625 Dalton, Sainte-Foy
Quec, Canada G1P 3S9
email:
web : www.gentec.ca
-------