This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Sending data received with BLE scanner to esp32 with uart

Hi everyone. I want to take advertising data with ble scanner and transmit to esp32 via uart. But I don't know how to do this. Is there an example for this? I need your help on this.

  • Hi Karl,

    I have a problem. I worked hard on this subject but every time i got error on app_uart_put(). I can't send data with app_uart_put() but when I use printf() I can read data from esp32. Which is correct for uart? And why?

  • What error do you get when you try to use app_uart_put?
    printf prints on UART if RETARGET_ENABLED is defined to 1 in the sdk_config.h.

    Best regards,
    Karl

  • When I use app_uart_put(), don't read received data. But I can read that on J-link RTT.

  • sasci said:
    When I use app_uart_put(), don't read received data.

    Specifically which error does the function return?
    Please make sure to have DEBUG defined in your preprocessor defines like shown in the included image:

    This will make your logger output a detailed error message whenever a non-NRF_SUCCESS error code is passed to an APP_ERROR_CHECK.

    sasci said:
    But I can read that on J-link RTT.

    If you have configured the logger to use the RTT backend you will see the NRF_LOG_* statements printed to RTT. The RTT terminal does not output UART messages.


    Best regards,
    Karl

Related