nRF UART central data send error

I'm trying to connect a nRF52832 DK to a secondary device (BLUETOOTH LOW ENERGY TINYSHIELD (ST)) where the nRF is the central. The example correctly connects to the board when it starts advertising but when I enter data over UART via PuTTY, I'm faced with an error (128).

I've tried to connect to a nRF52840 dongle with nRF connect and an Android phone setup with the UART service UUID and UART TX / UART RX characteristics. This behaves the same.

My second thought was that it has to do with security/bonding. However, since this is initiated from the Central, this would've been included in the NUS service included in the example so this doesn't seem correct. 

Since the error (128) means socket not connected, I figured there must be something wrong with the connection. I've tried to modify &nus_client in bt_nus_client_send() to NULL so it would be sent to any connection available. However, this results in an 'Operation already in progress' error (120). 

Any idea what I'm missing?

Parents
  • Hi Simon,

    Thanks for your reply. I'm using nRF Connect v1.7.1.

    Unfortunately, I do not have a second DK yet to try both the Peripheral and Central example at the same time. I've been trying to use the nRF Dongle in the mean time. I've tried to send UART data (PC->nRF52DK Central->nRF52 dongle) towards the dongle (set up as peripheral). This also results in the error. 

    When I use the nRF dongle as central, I can correctly communicate with my peripheral. When I send 'ab' over serial I see 61 62 appear in UART TX. When I enter 31 32 in UART RX, I see '12' over serial. 

    I've slightly modified the example to echo any UART data entered and I've added an extra scan filter so my peripheral is connected to when turned on. 

    Glenn

Reply
  • Hi Simon,

    Thanks for your reply. I'm using nRF Connect v1.7.1.

    Unfortunately, I do not have a second DK yet to try both the Peripheral and Central example at the same time. I've been trying to use the nRF Dongle in the mean time. I've tried to send UART data (PC->nRF52DK Central->nRF52 dongle) towards the dongle (set up as peripheral). This also results in the error. 

    When I use the nRF dongle as central, I can correctly communicate with my peripheral. When I send 'ab' over serial I see 61 62 appear in UART TX. When I enter 31 32 in UART RX, I see '12' over serial. 

    I've slightly modified the example to echo any UART data entered and I've added an extra scan filter so my peripheral is connected to when turned on. 

    Glenn

Children
No Data
Related