Beware that this post is related to an SDK in maintenance mode
More Info: Consider nRF Connect SDK for new designs
This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

gatt_evt_handler config to set data length to send data by uart

Hi,

I am adapting the uart example to send mensages between central and peripheral using JSON. In this moment I can send central <------>peripheral... 

I have a problem because there are a limitation to send string, the data length max is 61 characters.. any value biggest than 61, is send in another message. So when I want to parse message (in the receiver size) I can read only the first 61 characters. The remaining I lost...

I saw that the gatt_evt_handler method sets the m_ble_nus_max_data_len and this variable define the data size that will be send (uart_event_handle)

if ((data_array[index - 1] == '\n') || (index >= (m_ble_nus_max_data_len)))

Are there any way to send data string biggest than 61 characters in only one message??

Related