Hi mjbcswitzerland ,
Thanks for your valuable input.
I was trying to implement the same but faced certain issues while doing so.
I am using non blocking transfer method to send data through uart.
API's used in code:
1) status_t UART_TransferReceiveNonBlocking(UART_Type *base,uart_handle_t *handle,uart_transfer_t *xfer,size_t *receivedBytes)
2) void UART_TransferCreateHandle(UART_Type *base,uart_handle_t *handle,uart_transfer_callback_t callback,void *userData)
3) status_t UART_TransferSendNonBlocking(UART_Type *base, uart_handle_t *handle, uart_transfer_t *xfer)
I modified following snippets in firmware in "fsl_uart.c" file:
1) status_t UART_Init(UART_Type *base, const uart_config_t *config, uint32_t srcClock_Hz) :
Replaced ==> base->C2 &= ~(UART_C2_TE_MASK | UART_C2_RE_MASK);
With ==> base->C2 &= ~(UART_C2_TCIE_MASK | UART_C2_RE_MASK);
Replaced ==> if (config->enableTx)
{
temp |= UART_C2_TE_MASK;
}
With ==> if (config->enableTx)
{
temp |= UART_C2_TCIE_MASK;
}
2) status_t UART_TransferSendNonBlocking(UART_Type *base, uart_handle_t *handle,uart_transfer_t *xfer)
Replaced ==> UART_EnableInterrupts(base, kUART_TxDataRegEmptyInterruptEnable);
With ==> UART_EnableInterrupts(base, kUART_TransmissionCompleteInterruptEnable);
When i started debugging the firmware the controller stopped all of a sudden and now it is giving constant reset even if i try to debug any demo code.
Can you please help in resolving this issue.
Also, there is a guard time setting in K22 uart, will this setting help in acheiving the desired second stop bit delay?
Thanks and best regards,
Prasanna