Hi,
I initialize UART 3 in Uart call back mode
char scanPrompt_try[256];
UART_Params uartParams;
/* UART SoC init configuration */
UART_HwAttrs uart_cfg;
UART_init();
/***************************************UART_In_Callback();***************/
/* Create call back semaphore */
/* Get the default UART init configurations */
UART_socGetInitCfg(UART_INSTANCE, &uart_cfg);
uart_cfg.edmaHandle = NULL;
uart_cfg.dmaMode = FALSE;
uart_cfg.loopback = FALSE;
UART_socSetInitCfg(UART_INSTANCE, &uart_cfg);
/* Set callback mode for read */
UART_Params_init(&uartParams);
uartParams.readCallback = UART_callback;
uartParams.readMode = UART_MODE_CALLBACK;
uart = UART_open(UART_INSTANCE, &uartParams);
While(1)
{
Count_encoder=UART_read(uart, &scanPrompt_try,1);
if(Count_encoder!=UART_ERROR)
{
ACnt=ACnt+1;
UART_putNum_Anjana(ACnt);
}
if(ACnt>=196)
{
ACnt=0;
UART_write(uart, &scanPrompt_try, 3);
}
}
UART_read returns -1 and 0 but it does not return no of bytes read. Please tell me why is this so?
and many times is gives run time error after reading some bytes. and the run time error is CortexA15_0: Unhandled ADP_Stopped exception 0x20023
Thanks,
Anjana Pathak


