Am making a project based on NUS central demo and I can connect to our remote unit with the 52840DK, I can send data over a UART into it and I can get data out which is received on the remote BLE node.
I'd like to, well, need to, change the TX and RX characteristics to be 240 bytes in size.
I have seen here:
devzone.nordicsemi.com/.../extends-the-mtu-size-in-latest-zephyr
Someone talking about the maximum overall size (although I don't understand what he's saying in the answer).
Where are these used? ie What file would this be in?
CONFIG_BT_BUF_ACL_RX_SIZE instead of CONFIG_BT_L2CAP_RX_MTU (comes from l2cap.h,
#define BT_L2CAP_RX_MTU (CONFIG_BT_BUF_ACL_RX_SIZE - BT_L2CAP_HDR_SIZE)
And this:
Max payload size of adv_data with extended advertizement
I'd expect to see it in this:
/* UART Service Declaration */
BT_GATT_SERVICE_DEFINE(nus_svc,
BT_GATT_PRIMARY_SERVICE(BT_UUID_NUS_SERVICE),
BT_GATT_CHARACTERISTIC(BT_UUID_NUS_TX,
BT_GATT_CHRC_NOTIFY,
#ifdef CONFIG_BT_NUS_AUTHEN
BT_GATT_PERM_READ_AUTHEN,
#else
BT_GATT_PERM_READ,
#endif /* CONFIG_BT_NUS_AUTHEN */
NULL, NULL, NULL),
BT_GATT_CCC(nus_ccc_cfg_changed,
#ifdef CONFIG_BT_NUS_AUTHEN
BT_GATT_PERM_READ_AUTHEN | BT_GATT_PERM_WRITE_AUTHEN),
#else
BT_GATT_PERM_READ | BT_GATT_PERM_WRITE),
#endif /* CONFIG_BT_NUS_AUTHEN */
BT_GATT_CHARACTERISTIC(BT_UUID_NUS_RX,
BT_GATT_CHRC_WRITE |
BT_GATT_CHRC_WRITE_WITHOUT_RESP,
#ifdef CONFIG_BT_NUS_AUTHEN
BT_GATT_PERM_READ_AUTHEN | BT_GATT_PERM_WRITE_AUTHEN,
#else
BT_GATT_PERM_READ | BT_GATT_PERM_WRITE,
#endif /* CONFIG_BT_NUS_AUTHEN */
NULL, on_receive, NULL),
);
attr_char_value.max_len = TX_LEN;
err_code = sd_ble_gatts_characteristic_add( exlrt_service.service_handle,
&char_md,
&attr_char_value,
handle );