Reply
Posts: 48
Registered: ‎01-06-2017

No Response from BLE113 after sending User Read Response

Hi,

 

The BLE113 is connected to the EFM8LB through UART with flow control at 9600 bauds.

The MCU did not receive the response for the "User Read Response" command from the BLE. 

I am using ble-1.5.0-137.

 

Here is the sequence of exchanges between the BLE Client, BLE and the EFM.

The BLE client is the "nRF Connect" from Google Play Store.

 

 BLE Client                                       BLE                                        EFM

                                            System Boot event ------------------------>

                                                          <--------------------------------Hello command

                                               Hello response --------------------------->

                                                           <-------------------------------set gap_general_discoverable and                                                                                                                       gap_undirected_connectable

                                                Set Mode response----------------------->

                                                            <------------------------------set bondable mode(1)

                                                 Set Bondage response ----------------->

   Connect--------------------------------->

                                                Connect event ----------------------------->

   Read "Lock Running Modes"

   characteristic  ------------------------->

                                               User Read Request Event  ------------>

                                                                 <--------------------------- User Read Response

                                                                                                       command with data

                                                                -----------------------> ???? No response

 

Here is the User Read Response packet.

HiLen = 0

LoLen = 4

class =  2

method = 3

connection = 0

att _error = 0

value length = 1

value = 4

 

I also zipped up my bgproj and attached below. 

 

I am not sure what I missed. Thank you for your help.

 

Ron Yip

Posts: 48
Registered: ‎01-06-2017

Re: No Response from BLE113 after sending User Read Response

Instead of the read, I tried writing to the "Lock Running Modes" characteristic from the client after connection. The EFM received the Value event with the correct value. It sent the User Write Response value. Again, it did not receive a response and the client is not happy.

 

Ron

Posts: 48
Registered: ‎01-06-2017

Re: No Response from BLE113 after sending User Read Response

Figured out what the problem is.

 

The EFM was keeping the BLE was in sleep mode. After I set the BLE awake, it sent the response for the User Read Response and User Write Response correctly.

 

It seems when the BLE is in sleep mode, it still sends event to the host processor but does not respond to the commands?

Highlighted
Posts: 343
Registered: ‎10-07-2015

Re: No Response from BLE113 after sending User Read Response

Hello,

 

When the module is in advertising mode, it will send events to the host. However, it might be that in your case the module sleeps again (due to inactivity) and that is why there is no communication.

 

Regards,

Bartosz

Posts: 48
Registered: ‎01-06-2017

Re: No Response from BLE113 after sending User Read Response

@bpienk

 

How soon does the ble goes back to sleep after connection? I did not see a setting for this timer. 

 

Thank you,

Ron