Hi,
what is the board revision you have? If you have a scope/analyzer try to measure RX signal from MCU's PD12 pin back to K20's RXD_K20 pin, if you see character sent from PC. Use board schematic to know measure points.
You can simply add RX interrupt code for the LINFlexD_UART_MPC5744P demo example.
In main.c file use
void LINFlexD_1_RXISR(void)
{
echoLINFlexD_1();
}
__attribute__ ((section(".text")))
int main(void)
{
xcptn_xmpl (); /* Configure and Enable Interrupts */
peri_clock_gating(); /* Config gating/enabling peri. clocks for modes*/
/* Configuraiton occurs after mode transition */
system160mhz(); /* sysclk=160MHz, dividers configured, mode trans*/
initGPIO();
initLINFlexD_1(80,19200);
testLINFlexD_1(); /* Send test message to PC terminal.*/
/* enable RX interrupt */
LINFlexD_1.LINIER.R = 0x0004;
// assign required peripheral priorities
INTC_0.PSR[380].R = 0x8001; // LINFlex1_RXI
for(;;)
{
//echoLINFlexD_1();
}
; //Loop forever
return 0;
}
and put the address of interrupt routine into vector table.
So within intc_SW_mode_isr_vectors_MPC5744P.c add
/*========================================================================*/
/* PROTOTYPES */
/*========================================================================*/
void dummy (void);
extern void LINFlexD_1_RXISR(void);
and find proper line and change it to
(uint32_t) &dummy, /* Vector # 379 Reserved for LINFlex/eSCI0_3 LINFlex_0 */
(uint32_t) &LINFlexD_1_RXISR, /* Vector # 380 LINFlex_RXI LINFlex_1 */
(uint32_t) &dummy, /* Vector # 381 LINFlex_TXI LINFlex_1 */
BR, Petr