Hi,
i'm using S32k146 custom board PCB in that i'm trying to get the RX buffer using interrupt method but the thing is my interrupt call back function not triggering to get entire buffer.
for Example : if i send "AT+RESET" to MCU my call back function only triggering 3 times and i'm getting buffer only "AT" remaining buffer i'm not getting and my call back event is showing as "UART_EVENT_ERROR"
please go through the below given code for your reference
uart_init(void)
{
LPUART_DRV_Init(INST_LPUART1, &lpuart1_State, &lpuart1_InitConfig0);
LPUART_DRV_InstallRxCallback(INST_LPUART1, iot_rx_callback, NULL);
LPUART_DRV_SendDataBlocking(INST_LPUART1, ser_tx_cmd0, 4U, 100);
}
void iot_rx_callback(void *driverState, uart_event_t event, void *userData)
{
(void) driverState;
(void) userData;
if (event == UART_EVENT_RX_FULL)
{
if ((buffer[bufferIdx - 1] != '\r') && (buffer[bufferIdx] != '\n') && (bufferIdx != (BUFFER_SIZE - 1U)))
{
bufferIdx++;
LPUART_DRV_SetRxBuffer(INST_LPUART1, &buffer[bufferIdx++], 1U);
}
else
{
bufferIdx=0;
rx_complete = true;
}
}
}
while(1){
int ret =LPUART_DRV_ReceiveData(INST_LPUART1, buffer, 1U);
if(ret=STATUS_SUCCESS){
while(LPUART_DRV_GetReceiveStatus(INST_LPUART1, &bytesRemaining) == STATUS_BUSY);
ser_buffer_index=0;
}
/*********/
own code
/********/
}

my normal TX data is transmitting properly without any trouble only problem i'm facing in RX data