2017-02-23 09:39 AM
Hello I am using BlueNRG-ms and have a characteristic that is 52 bytes.
However when the client reads it they only get the first 20 something bytes, the rest dont get transfered. Both creating the characteristic and updating its value is successfull according to event complete parameters.
When i did this using the BlueNRG GUI, with the same size and same data it worked...
Char setup:
uint8_t data[] =
{ HIDServiceHandle[0], HIDServiceHandle[1], //Handle of the service to which the characteristic has to be added UUID16BIT, //0x01: 16-bit UUID0x4b, 0x2a, //UUID
0x34, 0x00, //Maximum length of the characteristic value
PROPERTY_READ, //Bitwise OR values of Characteristic Properties
0x00, //0x00: ATTR_PERMISSION_NONE
0x01, //0x01: GATT_SERVER_ATTR_WRITE The application will be notified when a client writes to this attribute
0x10, //The minimum encryption key size requirement for this attribute. Valid Range: 7 to 16
FIXEDLENGTH, //0x00: The attribute has a fixed length value field };
And the data:
uint8_t data[] =
{ HIDServiceHandle[0], HIDServiceHandle[1], //Service handleHIDReportMapCharactersiticHandle[0],HIDReportMapCharactersiticHandle[1], //Char handle
0x00, //ValueOffset
0x34, //Value length
0x05,0x01,
0x09,0x02,
0xA1,0x01,
0x09,0x01,
0xA1,0x00,
0x85,0x01,
0x05,0x09,
0x19,0x01,
0x29,0x03,
0x15,0x00,
0x25,0x01,
0x95,0x03,
0x75,0x01,
0x81,0x02,
0x95,0x01,
0x75,0x05,
0x81,0x03,
0x05,0x01,
0x09,0x30,
0x09,0x31,
0x15,0x81,
0x25,0x7F,
0x75,0x08,
0x95,0x02,
0x81,0x06,
0xC0,0xC0, };#stm32 #bluenrg-ms #hci #ble