This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

How send large notification?

Hello, In our project we want use a large characteristic with notification property.

I use a "ble_app_template" project from nRF5_SDK_14.2.0_17b948a\examples\ble_peripheral. In a project i added custom service with one characterics, it's length 200 byte. Property: Read;Write;Notification.

And I changed MTU size to 247.

So, as "master" I use Ubuntu PC with BlueZ stack. For connect uses "gatttool utility". After success connect in RTT i see:

<debug> nrf_sdh_ble: BLE event: 0x10.
<debug> ble_gatt: Requesting to update ATT MTU to 247 bytes on connection 0x0.
<debug> ble_gatt: Requesting to update data length to 251 on connection 0x0.
<info> app: Connected.
<debug> nrf_sdh_ble: BLE event: 0x24.
<debug> ble_gatt: Data length updated to 27 on connection 0x0.
<debug> ble_gatt: max_rx_octets: 27
<debug> ble_gatt: max_tx_octets: 27
<debug> ble_gatt: max_rx_time: 328
<debug> ble_gatt: max_tx_time: 328
<debug> nrf_sdh_ble: BLE event: 0x3A.
<debug> ble_gatt: ATT MTU updated to 23 bytes on connection 0x0 (response).
<debug> nrf_sdh_ble: BLE event: 0x12.

after in gatt tool i send command: mtu 247 for increase mtu size. In RTT added next:

<debug> nrf_sdh_ble: BLE event: 0x55.
<debug> ble_gatt: Peer on connection 0x0 requested an ATT MTU of 247 bytes.
<debug> ble_gatt: Updating ATT MTU to 247 bytes (desired: 247) on connection 0x0.

When I read a characterictics, I see all 200 bytes. But, If i enable notification, i receive only 20 bytes.

I don't understand, What have I forgotten to do yet?

P.S. Keil MDK, HW: PCA10040 v1.1.0, SW: S132

[00]ble_app_template.rar

Thanks, Best Regurds Max

Parents Reply Children
No Data
Related