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 again

    So, I set it up on my phone as well, just to make sure it works, and it does indeed, the settings on the nRFConnect app for the full Nordic UART service is just not as straight forward as you might think. I exported mine as an .xml file here so you can add it as a server in nRF Connect on your Android phone as well to make sure it works. 

    <server-configuration name="SLM_UART - copy">
       <service uuid="6e400001-b5a3-f393-e0a9-e50e24dcca9e">
          <characteristic uuid="6e400002-b5a3-f393-e0a9-e50e24dcca9e" value-string="fr99oooootkrororororororororororororororotoorororororororororrorororororororororoororororororoororor">
             <permission name="WRITE"/>
             <property name="WRITE"/>
             <property name="WRITE_WITHOUT_RESPONSE"/>
          </characteristic>
          <characteristic uuid="6e400003-b5a3-f393-e0a9-e50e24dcca9e">
             <descriptor configure="CCCD"/>
             <property name="NOTIFY"/>
          </characteristic>
       </service>
    </server-configuration>

    Best regards,

    Simon

Reply
  • Hi again

    So, I set it up on my phone as well, just to make sure it works, and it does indeed, the settings on the nRFConnect app for the full Nordic UART service is just not as straight forward as you might think. I exported mine as an .xml file here so you can add it as a server in nRF Connect on your Android phone as well to make sure it works. 

    <server-configuration name="SLM_UART - copy">
       <service uuid="6e400001-b5a3-f393-e0a9-e50e24dcca9e">
          <characteristic uuid="6e400002-b5a3-f393-e0a9-e50e24dcca9e" value-string="fr99oooootkrororororororororororororororotoorororororororororrorororororororororoororororororoororor">
             <permission name="WRITE"/>
             <property name="WRITE"/>
             <property name="WRITE_WITHOUT_RESPONSE"/>
          </characteristic>
          <characteristic uuid="6e400003-b5a3-f393-e0a9-e50e24dcca9e">
             <descriptor configure="CCCD"/>
             <property name="NOTIFY"/>
          </characteristic>
       </service>
    </server-configuration>

    Best regards,

    Simon

Children
No Data
Related