Skip to content

Commit bd86efd

Browse files
committed
Update some classes of CurieBLE library
Improve documentation and code formatting of BLEAttribute, BLECharacteristic and BLEProfile classes Signed-off-by: Biagio Montaruli <[email protected]>
1 parent f2a001f commit bd86efd

File tree

3 files changed

+6
-8
lines changed

3 files changed

+6
-8
lines changed

libraries/CurieBLE/src/BLEAttribute.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ class BLEAttribute {
7070
* @param[in] uuidsize The max size of UUID
7171
*
7272
* @return bool true - UUID is the same with data
73-
* false- UUID is not the same with data
73+
* false- UUID is not the same with data
7474
*
7575
* @note none
7676
*/
@@ -104,7 +104,7 @@ class BLEAttribute {
104104
void setHandle(uint16_t handle);
105105

106106
static unsigned char numAttributes(void);
107-
// The below APIs are for central device to discover the
107+
// The below APIs are for central device to discover peripheral devices
108108
virtual void discover(bt_gatt_discover_params_t *params) = 0;
109109
virtual void discover(const bt_gatt_attr_t *attr,
110110
bt_gatt_discover_params_t *params) = 0;

libraries/CurieBLE/src/BLECharacteristic.h

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ class BLECharacteristic : public BLEAttribute {
166166
*
167167
* @param none
168168
*
169-
* @return unsigned char The totla number of the notify attributes
169+
* @return unsigned char The total number of the notify attributes
170170
*
171171
* @note none
172172
*/
@@ -303,8 +303,6 @@ class BLECharacteristic : public BLEAttribute {
303303

304304
private:
305305
void _setValue(const uint8_t value[], uint16_t length);
306-
307-
private:
308306

309307
static unsigned char _numNotifyAttributes;
310308
static bt_uuid_16_t _gatt_chrc_uuid;
@@ -329,7 +327,7 @@ class BLECharacteristic : public BLEAttribute {
329327
bt_gatt_attr_t *_attr_cccd;
330328

331329
// For central device to subscribe the Notification/Indication
332-
bt_gatt_subscribe_params_t _sub_params;
330+
bt_gatt_subscribe_params_t _sub_params;
333331

334332
bool _reading;
335333
bt_gatt_read_params_t _read_params;

libraries/CurieBLE/src/BLEProfile.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ class BLEProfile{
166166
* @param[in] BLEAttribute * The BLEAttribute object
167167
*
168168
* @return bt_gatt_attr_t* NULL - Not found
169-
* Not NULL - The bt_gatt_attr in the stack
169+
* Not NULL - The bt_gatt_attr in the stack
170170
*
171171
* @note none
172172
*/
@@ -206,7 +206,7 @@ class BLEProfile{
206206
BLEAttribute** _attributes;
207207
uint16_t _num_attributes;
208208

209-
bt_gatt_subscribe_params_t *_sub_param;
209+
bt_gatt_subscribe_params_t *_sub_param;
210210
int _sub_param_idx;
211211

212212
bt_gatt_discover_params_t _discover_params;

0 commit comments

Comments
 (0)