cancel
Showing results for 
Search instead for 
Did you mean: 

Increase size of sent data by BLE client

Kolab
Senior

Hi! I flashed my USB dongle with BLE_p2p_client application that I edited on my own. But I can not send more than 3 bytes using aci_gatt_write_without_resp in function tBleStatus Write_Char in the file p2p_client_app.c . Even if I increase CharValLenght to something higher nothing changes, only 3 bytes are received by server. Can someone please suggest me what to do?

3 REPLIES 3
Remi QUINTIN
ST Employee

By default the ATT_MTU = 27 for all GATT packets (BLE standard).

Since BLE V4.2, it is possible to extend the payload size after a negotiation in between two devices using aci_gatt_exchange_config.

Now your issue may not be linked to the size of the payload.

What is the configuration? Services and characteristics, data size? Are they new services you created?

What did you change/ modify with the BLE_p2pClient application.

I am not aware of any p2p_client_server.c file.

sorry it was a mistake in the file denomination, I've corrected.

These are the service and characteristics in the server side. I use the default one. I only changed the CharValueLegth parameter and set ATT_MTU to 156

0693W000000WWoHQAW.png

In the file p2p_client_app.c the issue was when in the I changed charValueLen in the function

tBleStatus Write_Char(uint16_t UUID, uint8_t Service_Instance, uint8_t *pPayload);     and I set ATT_MTU to 156

ret =aci_gatt_write_without_resp(aP2PClientContext[index].connHandle,

                     aP2PClientContext[index].P2PWriteToServerCharHdle,

                     156, /* charValueLen */

                     (uint8_t *) pPayload);

When I put charValueLen to some number more that 3, the client board cannot send notifications any more.

Kolab
Senior

so, any ideas?