Hi it's me again. I have still problems with Interrupts on the C5402 DSK Board. I'm not able to fix my interrupt problem. I found the TI documentation very horrible. There are no source code examples that show how external interrupts are realised in C. I found many different header files that use the IMR register. In each file the register is accessed different. This files are the C54.h, intr.h or hwi.h . I've tried to a BIOS configuration file to handle the interrupts, and another time I tried to use the interrupt keyword, but it never runs. Who can help me to fix my problem. I want to use an external interrupt that is triggered by an externel event (clock or somethin else) to read from an IO port of the C54X. It would also be helpfull if someone could explain me which steps has to be done to realise an interrupt routine. - how can I set the IMR register for the external interrupts - hwo are interrupts globally enabled (like INTR_GLOBAL_ENABLE; from intr.h or C54_enable() from C54.h) - how are interrupt routines written in C (e.g. interrupt void INT0 () ) This is a code I tried out: #include <std.h> #include <c54.h> ioport Uns port8000; Uns uData; interrupt void INT1() { uData = port8000; } void main(void) { C54_enableIMR(C54_INT1); C54_enable(); while(1); } Thanks for any help. Christian |
|
Interrupts with CCS
Started by ●March 13, 2001
Reply by ●March 13, 20012001-03-13
The only way I've got these to work is by following the example in the
CCS tutorial book which has the hardware interrupt firing off a software interrupt. Shortcutting the thing never worked. Jeff -----Original Message----- From: Christian Dolzer [mailto:] Sent: Tuesday, March 13, 2001 7:18 AM To: Subject: [c54x] Interrupts with CCS Hi it's me again. I have still problems with Interrupts on the C5402 DSK Board. I'm not able to fix my interrupt problem. I found the TI documentation very horrible. There are no source code examples that show how external interrupts are realised in C. I found many different header files that use the IMR register. In each file the register is accessed different. This files are the C54.h, intr.h or hwi.h . I've tried to a BIOS configuration file to handle the interrupts, and another time I tried to use the interrupt keyword, but it never runs. Who can help me to fix my problem. I want to use an external interrupt that is triggered by an externel event (clock or somethin else) to read from an IO port of the C54X. It would also be helpfull if someone could explain me which steps has to be done to realise an interrupt routine. - how can I set the IMR register for the external interrupts - hwo are interrupts globally enabled (like INTR_GLOBAL_ENABLE; from intr.h or C54_enable() from C54.h) - how are interrupt routines written in C (e.g. interrupt void INT0 () ) This is a code I tried out: #include <std.h> #include <c54.h> ioport Uns port8000; Uns uData; interrupt void INT1() { uData = port8000; } void main(void) { C54_enableIMR(C54_INT1); C54_enable(); while(1); } Thanks for any help. Christian _____________________________________ 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: Send an email to To Post: Send an email to To Leave: Send an email to Archives: http://www.yahoogroups.com/group/c54x Other Groups: http://www.dsprelated.com ">http://docs.yahoo.com/info/terms/ |