| ??? 07/11/01 13:26 Read: times |
#13141 - RE: boot, applicative progr. with interrupts |
Here a solution I often use for such problems:
The only disadvantage of this solution you will need 2 bytes of IMEM for each irq vector you want to use. You have to compile your C Files with NOIV in the commandline Thomas 1 write a assembler file you have to link the ASM File with your Boot Code extrn DATA (EXT_VECT) extrn DATA (T0_VECT) CSEG at 0003h push EXT0_Vect+1 ;MSB push EXT0_Vect+0 ;LSB ret org 0bh push T0_Vect+1 ;MSB push T0_Vect+0 ;LSB ret .... end In your C files : unsigned int EXT0_Vect unsigned int EXT1_Vect void InitEXTVect(UINT8 code *pc) { EXT_Vect=pc; } void InitT0Vect(UINT8 code *pc) { T0_Vect=pc; } void main (void) { InitEXT0Vect(Ext0IrqRoutine); InitEXT0Vect(T0IrqRoutine); EA=1; ... } |
| Topic | Author | Date |
| boot, applicative progr. with interrupts | 01/01/70 00:00 | |
| RE: boot, applicative progr. with interrupts | 01/01/70 00:00 | |
| RE: boot, applicative progr. with interrupts | 01/01/70 00:00 | |
RE: boot, applicative progr. with interrupts | 01/01/70 00:00 |



