I want to link two PEC Channels together but after the first one has reached COUNT 00, the other channel doesn't start the transfer. Can somebody tell me exactly how do i have to set all the registers. Or is an application note available? Regards Marco
I'm using the uVision3 IDE and the MCBXC167-Net Board with XC167 Controller. Regards Marco
Hi Marco, if I understand the functionality of PEC channel link right , I wrote a simple program I tested the PEC channel link with. It simply writes some data bytes to CAPCOM6. The problem is to link the right channels with right level and priorities. I can send it to you without warranty, if you are interested.
main.c ....... INT_vSetPecSrcP(0, &PEC_Channel_0_Data) INT_vSetPecDesP(0, &CCU6_CC60SR) INT_vSetPecSrcP(1, &PEC_Channel_1_Data) INT_vSetPecDesP(1, &CCU6_CC60SR) // Set PEC Channel Link bit CL for PEC //channel 0 PECC0 |= 0x0800; PECC1 |= 0x0800; while(1) { ; } ........ int.c ........ if(PECISNC_C0IR) // end of PEC channel 0 { PECISNC_C0IR = 0; // Update of PEC channel 0 stuff IO_vTogglePin(P9_P4); printf("\nPEC0"); PECC0 = 0x5408; // load PECC0 control register PECC0 = 0x5408; // reset PEC pointer to begin of // Channel_0_Data INT_vSetPecSrcP(0,&PEC_Channel_0_Data) INT_vSetPecDesP(0, &CCU6_CC60SR) // Set PEC Channel Link bit CL for PEC // channel 0 PECC0 |= 0x0800; } if(PECISNC_C1IR) // end of PEC channel 1 { PECISNC_C1IR = 0; IO_vTogglePin(P9_P4); printf("\nPEC1"); PECC1 = 0x5408; INT_vSetPecSrcP(1,&PEC_Channel_1_Data) INT_vSetPecDesP(1, &CCU6_CC60SR) // Set PEC Channel Link bit CL for PEC // channel 1 PECC1 |= 0x0800; } .......