BLE BLERemoteCharacteristic Notify misses Bytes

AntonWert
Posts: 1
Joined: Sun Mar 10, 2024 9:10 am

BLE BLERemoteCharacteristic Notify misses Bytes

Postby AntonWert » Sun Mar 10, 2024 9:16 am

Hello,

with Arduino I do want to recive Data from an BLE device.
Based on existing code for Raspberry (witch is working I confirmed) I got the device connected, connected to the service, registered the callback for Notify and send the request byte.
All is working.
I even get the Callback fired, but only 20 out of over 40 Bytes recived.
I also confirmed the behavior with an BLE App for iOS, where I also get all bytes.

Is there any point where I can define the number of bytes I want to get? How can I get all data?

Anton

MicroController
Posts: 1688
Joined: Mon Oct 17, 2022 7:38 pm
Location: Europe, Germany

Re: BLE BLERemoteCharacteristic Notify misses Bytes

Postby MicroController » Thu Mar 14, 2024 10:58 pm

https://community.nxp.com/t5/Wireless-C ... -p/1129270
BLE standard define two ways to transfer data for the server to the client: notification and indication. Maximum data payload size defined by the specification in each message is 20 bytes.

chegewara
Posts: 2362
Joined: Wed Jun 14, 2017 9:00 pm

Re: BLE BLERemoteCharacteristic Notify misses Bytes

Postby chegewara » Fri Mar 15, 2024 2:08 am

MicroController wrote:
Thu Mar 14, 2024 10:58 pm
https://community.nxp.com/t5/Wireless-C ... -p/1129270
BLE standard define two ways to transfer data for the server to the client: notification and indication. Maximum data payload size defined by the specification in each message is 20 bytes.
I am suggesting to answer in topics you know. In this case maybe its worth to read about MTU?
You can send/receive notifications/indications in size over 500 bytes.

MicroController
Posts: 1688
Joined: Mon Oct 17, 2022 7:38 pm
Location: Europe, Germany

Re: BLE BLERemoteCharacteristic Notify misses Bytes

Postby MicroController » Fri Mar 15, 2024 10:10 am

chegewara wrote:
Fri Mar 15, 2024 2:08 am
I am suggesting to answer in topics you know. In this case maybe its worth to read about MTU?
You can send/receive notifications/indications in size over 500 bytes.
So you could have just shared this for the OP to try out?

chegewara
Posts: 2362
Joined: Wed Jun 14, 2017 9:00 pm

Re: BLE BLERemoteCharacteristic Notify misses Bytes

Postby chegewara » Tue Mar 19, 2024 3:03 pm

MicroController wrote:
chegewara wrote:
Fri Mar 15, 2024 2:08 am
I am suggesting to answer in topics you know. In this case maybe its worth to read about MTU?
You can send/receive notifications/indications in size over 500 bytes.
So you could have just shared this for the OP to try out?
Or any of link below, rather than saying that 20 in MAX by bluetooth specification, which is wrong:
https://github.com/espressif/esp-idf/issues/3315
viewtopic.php?t=1989
https://github.com/esphome/issues/issues/4041
viewtopic.php?t=4546

Who is online

Users browsing this forum: No registered users and 54 guests