Hi,
I like to add a interrupt function to the PIE Controller (RX and TX SCI-B).
DINT;
PieCtrlRegs.PIECTRL.bit.ENPIE = 1; // Enable the PIE block
PieCtrlRegs.PIEIER9.bit.INTx3=1; // PIE Group 9, INT3
PieCtrlRegs.PIEIER9.bit.INTx4=1; // PIE Group 9, INT4
unsigned x=IER ; // Enable CPU INT
x|= 0x100;
// IER=x;
EDIS; // This is needed to disable write to EALLOW protected registers
EINT;
If I run this code:
// IER=0x100;
unsigned x=IER ; // Enable CPU INT
x|= 0x100;
IER=x;
My SCI-B interface work but all other interrupts fail. Timer 2 and ADC(MainISR). If I comment the line out, both interrupt works again but SCI-B don't. I tried it in the hall but without success. Any suggestion what the problem is.
Thanks!
Edit: problem is in other place then I was search. When I disable TX interrupt the other interrupt works. So TX causes the the other interrupts don't get services.