Hi
I am facing a problem similar to the one in Case ID228253.
I am using a custom 52810 board and have configured the UART pins on P0.12(Tx) and P0.14(Rx), defined in the board file pca10040.h. (I have copied the defaults into a different header file and set the new pin assignments, then included my header file in boards.h.
On the custom board, the UART TX and RX lines are by default left floating and used only for debugging. I do not use the UART to send receive data, the data comes from an ADC channel and goes to the mobile app.
The software application is based on the ble_app_uart example.
As soon as the uart init() is called, i have a printf call to tell me that the initialization is done. But when the execution hits this call,
the code goes into the error handler.
When i debug the code, i find that it is coming into the uart_event_handle () function and landing at the following switch case in function uart_event_handler() in file app_uart_fifo.c file
case NRF_DRV_UART_EVT_ERROR:
app_uart_event.evt_type = APP_UART_COMMUNICATION_ERROR;
app_uart_event.data.error_communication = p_event->data.error.error_mask;
(void)nrf_drv_uart_rx(&app_uart_inst, rx_buffer, 1);
m_event_handler(&app_uart_event);
break;
The call stack shows the execution going into the error handler after all the characters in the printf string are sent out of the uart., please check it out at this link:
https://drive.google.com/file/d/1uxJfikgmhw4lHbLqVzcKtdD6ZFBr2VHV/view?usp=sharing
When i comment out the call to the error handler, in function uart_event_handle( ), like this
case APP_UART_COMMUNICATION_ERROR:
// APP_ERROR_HANDLER(p_event->data.error_communication);
break;
then it does not stop but works fine, i am able to get the module to advertise and connect to the phone, send/receive data...
However, this is not the right way to proceed !! Please let me know how to resolve this .....
Regards
Chary BS