Hello,
i am using the IPC peripheral in CtoM mode.
I create my own function to make a data transfert
void ctomTransfert (Uint16 data) {
while (CtoMIpcRegs.MTOCIPCSTS.bit.IPC17 != 1) { }
CtoMIpcRegs.MTOCIPCACK.bit.IPC17 = 1;
usWWord16 = data;
// 16 and 32-bit Data Writes
// Write 16-bit word to M3 16-bit write word variable. //
IPCCtoMDataWrite(&g_sIpcController1, pulMsgRam[0],(Uint32)usWWord16, IPC_LENGTH_16_BITS, ENABLE_BLOCKING, NO_FLAG);
// Wait until read variables are ready (by checking IPC Response Flag is // cleared). Then check Read var = Write var
while (CtoMIpcRegs.CTOMIPCFLG.bit.IPC17) { }
}
This function works very fine when I am using it in my main function.
The function is declared as a static inline function in the header file
But when I try to using it in the interrupt routine of a timer, the function is well execute but the trensfert didn't work. (There is no interruption in the m3 core)
does anyone has an idea why ?
Thanks in advance
Adrien