Re: how to increase RX buffer of characteristic for BLE device

Luiz Augusto von Dentz


On Sat, Mar 17, 2018 at 1:08 PM, Vikrant More <> wrote:

static ssize_t ABCD_write(struct bt_conn *conn, const struct bt_gatt_attr
*attr, const void *buf, u16_t len, u16_t offset, u8_t flags)
u8_t *value = attr->user_data;

if (offset + len > 64)

memcpy(value + offset, buf, offset + len);

printk("\n\roffset = %d, len = %d\n\r", offset, len);

return len;

For testing I'm sending random 64 bytes of data to one characteristic
using #nrfConnect App but on device side it accepting only 20 Bytes.

printk("\n\roffset = %d, len = %d\n\r", offset, len); <--- Here len = 20
even when actual data size is 64.

So how to increase this limit upto 64 bytes ?
You should probably need to increase the MTU size, though both client
and server have to agree on the MTU, also it is possible to that the
app is using long write procedure so more bytes would follow...

Thank You !!

Zephyr-users mailing list

Luiz Augusto von Dentz

Join to automatically receive all group messages.