File tree Expand file tree Collapse file tree 3 files changed +4
-6
lines changed
libraries/Bluefruit52Lib/src Expand file tree Collapse file tree 3 files changed +4
-6
lines changed Original file line number Diff line number Diff line change @@ -267,7 +267,7 @@ void BLEGap::_eventHandler(ble_evt_t* evt)
267
267
268
268
case BLE_GATTS_EVT_EXCHANGE_MTU_REQUEST:
269
269
{
270
- peer->att_mtu = minof (evt->evt .gatts_evt .params .exchange_mtu_request .client_rx_mtu , BLEGATT_ATT_MTU_MAX );
270
+ peer->att_mtu = minof (evt->evt .gatts_evt .params .exchange_mtu_request .client_rx_mtu , Bluefruit. getMaxMtu () );
271
271
VERIFY_STATUS ( sd_ble_gatts_exchange_mtu_reply (conn_handle, peer->att_mtu ), );
272
272
273
273
LOG_LV1 (" GAP" , " ATT MTU is changed to %d" , peer->att_mtu );
Original file line number Diff line number Diff line change 44
44
45
45
/* Note changing these parameters will affect APP_RAM_BASE
46
46
* --> need to update RAM region in linker file
47
- *
48
- * default value are
49
47
* - BLEGATT_ATT_MTU_MAX from 23 (default) to 247
50
48
*/
51
49
Original file line number Diff line number Diff line change @@ -160,7 +160,7 @@ void BLEUart::bufferTXD(uint8_t enable)
160
160
if ( _tx_fifo == NULL )
161
161
{
162
162
_tx_fifo = new Adafruit_FIFO (1 );
163
- _tx_fifo->begin (BLEGATT_ATT_MTU_MAX );
163
+ _tx_fifo->begin ( Bluefruit. getMaxMtu () );
164
164
}
165
165
}else
166
166
{
@@ -182,7 +182,7 @@ err_t BLEUart::begin(void)
182
182
_txd.setProperties (CHR_PROPS_NOTIFY);
183
183
// TODO enable encryption when bonding is enabled
184
184
_txd.setPermission (SECMODE_OPEN, SECMODE_NO_ACCESS);
185
- _txd.setMaxLen (BLEGATT_ATT_MTU_MAX );
185
+ _txd.setMaxLen ( Bluefruit. getMaxMtu () );
186
186
_txd.setUserDescriptor (" TXD" );
187
187
VERIFY_STATUS ( _txd.begin () );
188
188
@@ -192,7 +192,7 @@ err_t BLEUart::begin(void)
192
192
193
193
// TODO enable encryption when bonding is enabled
194
194
_rxd.setPermission (SECMODE_NO_ACCESS, SECMODE_OPEN);
195
- _rxd.setMaxLen (BLEGATT_ATT_MTU_MAX );
195
+ _rxd.setMaxLen ( Bluefruit. getMaxMtu () );
196
196
_rxd.setUserDescriptor (" RXD" );
197
197
VERIFY_STATUS (_rxd.begin ());
198
198
You can’t perform that action at this time.
0 commit comments