Increase the BLE packet size
Devices supporting BLE 4.2 (or higher) can use data packets with a payload size of up to 244 bytes. None of the current Mares models support this at the moment, but increasing the size on the receiving side already prepares the code for future models and remains fully backwards compatible.
This commit is contained in:
parent
4914f6bff3
commit
89a28427d6
@ -414,7 +414,7 @@ mares_iconhd_device_open (dc_device_t **out, dc_context_t *context, dc_iostream_
|
|||||||
|
|
||||||
// Create the packet stream.
|
// Create the packet stream.
|
||||||
if (transport == DC_TRANSPORT_BLE) {
|
if (transport == DC_TRANSPORT_BLE) {
|
||||||
status = dc_packet_open (&device->iostream, context, iostream, 20, 20);
|
status = dc_packet_open (&device->iostream, context, iostream, 244, 20);
|
||||||
if (status != DC_STATUS_SUCCESS) {
|
if (status != DC_STATUS_SUCCESS) {
|
||||||
ERROR (context, "Failed to create the packet stream.");
|
ERROR (context, "Failed to create the packet stream.");
|
||||||
goto error_free;
|
goto error_free;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user