Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

Hello everybody,

I'm working on SDK 2.2.1 and with the BCM20736S BLE module.

It's working as a BLE/PUART-bridge connected to a host MCU.

We have several custom characteristics and services, that are all found via Smart WICED Smart Explorer on Android and by our own App on iOS.

We can receive and send on two characteristics that contain 5 bytes payload for each direction. For larger data transfer we also have four writable and four notifyable characteristics with 20 bytes each. All characteristics have the same set of properties, descriptors and permissions and only differ in size.

Writing from iPhone into the four writable characteristics with 20 bytes works flawlessly and the data also appears on PUART.

But after that the app receives the four notifyable characteristics with 20 bytes payload without any payload and without a sendNotification on the BLE module.

Without payload means you'll get an update event issued by the iPhone bluetooth API that contains just NULL instead of an array containing the payload. We didn't find these strange notification with a BLE sniffer (Peryton BLE).

Thanks for any help and suggestions!

Best regards

Hannes Baumgart

0 Likes
1 Solution

I looked briefly at the code, and it looks that when you receive a Write Command on one of the characteristics, you send 5 notifications.  This should work fine as long as you do not send your Write Commands too often.  If you send Write Command every connection interval, it might not work well even if there is no interference and no need for retransmissions.  By default there are 4 notifications that you can squeeze in the connection interval.  You can try to increase this number to 6 by calling blecm_setMaxTxRxPair (6).  I am not sure if it is a well tested scenario though.

There is a limited number of tx buffers.  If you are after high performance, it is a good idea to check blecm_getAvailableTxBuffers() before sending the next notification.

Please add following 2 lines to your create function.  Setup for the UART trace in the console window of the IDE, repro the problem and attach trace here.

extern UINT32 blecm_configFlag ;

blecm_configFlag |= BLECM_DBGUART_LOG | BLECM_DBGUART_LOG_L2CAP | BLECM_DBGUART_LOG_SMP;

View solution in original post

0 Likes
11 Replies