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

ATT MTU vs Data length

I am trying to support old phones without BLE 4.2 data length extension. 

I have read https://punchthrough.com/pt-blog-post/maximizing-ble-throughput-part-2-use-larger-att-mtu/ and am now confused. 

The article says that ATT MTU can be any value from 23-infinity, but in nRF SDK 14.0.0 S132 5.0.0, I get this compile error, implying ATT MTU cannot be above 251. 

./components/ble/nrf_ble_gatt/nrf_ble_gatt.c:55:1: error: size of unnamed array is negative
 STATIC_ASSERT(NRF_SDH_BLE_GATT_MAX_MTU_SIZE + L2CAP_HDR_LEN <= 255);

ATT MTU and "data length" are different right? Can I have a ATT MTU of 251 and a data length of 23? Does that mean I can place 251 bytes of data into my characteristic at a time and watch it go over the air in 23-byte chunks? 

Related