Master-slave conne

I now want to have the host and slave in SDK17.1.0 to establish master/slave communication.

What if I change? If I use nRF5_SDK_17.1.0\examples\ble_central\ble_app_uart_c as the host, The device does not use nRF5_SDK_17.1.0\examples\ble_peripheral\ble_app_uart as the slave. They can't establish communication.

Now the question is do only ble_central\ble_app_uart_c as the host and ble_peripheral\ble_app_uart as the slave set up communication?

And if they can establish communication, on the host side, where do I know they have established communication?

What should I do if I want to make a host connection to a specified slave?

Thank you very much.

  • Thank you for reading my questions carefully and answering them in detail. Thank you so much
  • Hi,

    What if I change?

    From what I can understand the two samples you have found Bluetooth central and peripheral UART should do exactly what you need. Did it not work for your? Or what is the problem?

    Now the question is do only ble_central\ble_app_uart_c as the host and ble_peripheral\ble_app_uart as the slave set up communication?

    Yes, that is the case. In Bliuetooth terms, the Central can be thought of as the host or master, and the peripheral the slave.

    And if they can establish communication, on the host side, where do I know they have established communication?

    The Central example will print out "Connected to device with Nordic UART Service." over RTT (these samples use RTT instead of UART for logging, as the UART is used for the example itself, which is tunneling UART over Bluetooth).

    What should I do if I want to make a host connection to a specified slave?

    Then you can filter on the Bluetooth address or name or other parameter you prefer on the central side. There are some examples in the SDK for that and you can refer to the Scanning Module documentation for details.

  • thank you .now ,i do other thing. I have other things to do now, I'll do him later

Related