I use a PRoC in a project where it communicate with an uart to an other device (the main device).
The user use his phone to send commands and or parameters to the main device, and the phone app should be able to tell him that the orders have been correctly received by the main device.
So after a command, the PRoC receive the data, send it throught UART, the device make some action according to the received command and send an UART frame to confirm that it have take the command into account.
Where it's not clear it's how i should create characteristics.
Does i have to create many characterisitics for each parameters, or few big ones :
Few larges characteristics, with a 20 bytes arrays, and each one contains many parameters (like 5-6 parameters)
The problem with that solution is, that if the user change one parameters on the phone the app phone have to read the entire caracteristics and then change only one parameter with a mask.
2) one parameter per characteritic, its very structured, but the problem is that we have a lots of parameters to read and lots information to read from the main device (like date of first entry into service, software version etc, lots of large 32 or 64 bits long parameters). So with that solution, i need like at least 30 differents characteristics.
Other question, about the verification ( be sure that the data have been received by the main device).
Does i have to use :
one characteritics write and read per parameters ( or set of parameters) : the phone app send data to the caracteristic in the BLE device, but the handle is updated only when and if the confirmation is returned from the main device by an uart frame.
2) 2 characterisitics, one for the phone app to write the data and the other one to read the data (this second one is only writed by the main device with uart frame). The uart app suscribe from notification on the read characteritics
3) Just write the data in characteritics and assume that the data have been correctly delivered to the main device
What approches are best suited for our application ?
Thanks for you help.