ArduinoCore-arc32 icon indicating copy to clipboard operation
ArduinoCore-arc32 copied to clipboard

Fix GIT #516 and 517 return success when respond with error

Open sgbihu opened this issue 8 years ago • 4 comments

Root cause

  1. The return value indecate the read/write request send successfully.
  2. The subscribe will ignore the response and this will not be fixed.

Solution

  1. Add the error detect based on read/write response.

Changed files BLECallbacks.cpp - Delete the error check for read response. BLECharacteristicImp.cpp

  • Add the error check.
  • Optimize the memory allocate and clear the allocated memory. BLECharacteristicImp.h - Add varibles to flag the response error

sgbihu avatar Mar 31 '17 01:03 sgbihu

The subscribe will ignore the response and this will not be fixed.

Will this be fixed later?

sandeepmistry avatar Mar 31 '17 12:03 sandeepmistry

This always ignore the response in the stack. So the application can't get the result. This is the stack's limitation. And the return value stand for the gatt ccc write request send out. And it is an unblock call. I think we will not fix for the subscribe API.

sgbihu avatar Apr 01 '17 05:04 sgbihu

Is this a limitation of the firmware?

And it is an unblock call. I think we will not fix for the subscribe API.

I expect characteristic.subscribe() and characteristic.unsubscribe() to block.

sandeepmistry avatar Apr 03 '17 12:04 sandeepmistry

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

CLAassistant avatar Apr 09 '21 13:04 CLAassistant