Skip to content

Commit 3c3592a

Browse files
committed
BLE: Update documentation.
Fix typos, spelling and conjugation.
1 parent 67b47ca commit 3c3592a

16 files changed

+87
-87
lines changed

features/FEATURE_BLE/ble/BLE.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,7 @@ class BLE
202202
OnEventsToProcessCallback_t;
203203

204204
/**
205-
* Register a callback called when the BLE stack has pending work.
205+
* Register a callback called when the BLE stack has pending work.
206206
*
207207
* By registering a callback, application code can know when event processing
208208
* has to be scheduled.

features/FEATURE_BLE/ble/BLEInstanceBase.h

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -89,8 +89,8 @@ class BLEInstanceBase
8989
/**
9090
* Start the initialization of the vendor BLE subsystem.
9191
*
92-
* Call to this function is initiated by BLE::init, instanceID identify the
93-
* BLE instance which issue that call while the initCallback is used to
92+
* Calls to this function are initiated by BLE::init, instanceID identify
93+
* the BLE instance which issue that call while the initCallback is used to
9494
* signal asynchronously the completion of the initialization process.
9595
*
9696
* @param[in] instanceID Identifier of the BLE instance requesting
@@ -166,7 +166,8 @@ class BLEInstanceBase
166166
/**
167167
* Accessor to the vendor implementation of the Gap interface.
168168
*
169-
* @return A reference to a Gap object associated to this BLE instance.
169+
* @return A reference to a Gap object associated to this BLEInstanceBase
170+
* instance.
170171
*
171172
* @see BLE::gap() Gap
172173
*/
@@ -254,7 +255,7 @@ class BLEInstanceBase
254255
* Return the instance of the vendor implementation of BLEInstanceBase.
255256
*
256257
* @important Contrary to its name, this function does not return a new instance
257-
* at eachcall. It rather act like an accessor to a singleton.
258+
* at each call. It rather act like an accessor to a singleton.
258259
*
259260
* @important An implementation for this function must be provided by the vendor
260261
* library, otherwise there will be a linker error.

features/FEATURE_BLE/ble/BLETypes.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
namespace ble {
3131

3232
/**
33-
* Opaque reference to a connection
33+
* Opaque reference to a connection.
3434
*
3535
* Internally a connection handle is an unsigned integer capable of holding a
3636
* pointer.
@@ -67,7 +67,7 @@ struct attribute_handle_range_t {
6767
* Equal operator for attribute_handle_range_t.
6868
*
6969
* @param[in] lhs Left hand side of the expression.
70-
* @param[in] rhs Left hand side of the expression.
70+
* @param[in] rhs Right hand side of the expression.
7171
*
7272
* @return true if lhs is equal to rhs and false otherwise.
7373
*/
@@ -81,7 +81,7 @@ struct attribute_handle_range_t {
8181
* Not equal operator for attribute_handle_range_t.
8282
*
8383
* @param[in] lhs Left hand side of the expression.
84-
* @param[in] rhs Left hand side of the expression.
84+
* @param[in] rhs Right hand side of the expression.
8585
*
8686
* @return true if lhs is not equal to rhs and false otherwise.
8787
*/

features/FEATURE_BLE/ble/CallChainOfFunctionPointersWithContext.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@
7272
* }
7373
* @endcode
7474
*
75-
* @note memory allocation is used to add new function like object into the
75+
* @note memory allocation is used to add new function like objects into the
7676
* call chain.
7777
*
7878
* @tparam ContextType Type of the parameter accepted by the callbacks hosted
@@ -270,11 +270,11 @@ class CallChainOfFunctionPointersWithContext :
270270
* @code
271271
* CallChainOfFunctionPointersWithContext<void *> chain;
272272
*
273-
* if (chain) {
273+
* if (!chain) {
274274
* // Do something if the chain is empty.
275275
* }
276276
*
277-
* if (!chain) {
277+
* if (chain) {
278278
* // Do something if the chain is not empty.
279279
* }
280280
* @endcode

features/FEATURE_BLE/ble/CharacteristicDescriptorDiscovery.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ class CharacteristicDescriptorDiscovery {
100100
/**
101101
* Characteristic descriptor discovered event handler.
102102
*
103-
* As parameter it expect a pointer to a DiscoveryCallbackParams_t instance.
103+
* As parameter it expects a pointer to a DiscoveryCallbackParams_t instance.
104104
*
105105
* @note The object passed in parameter will remain valid for the lifetime
106106
* of the callback. Memory for this object is owned by the BLE_API eventing
@@ -117,7 +117,7 @@ class CharacteristicDescriptorDiscovery {
117117
/**
118118
* Handler of Characteristic descriptor discovery ended event.
119119
*
120-
* As parameter it expect a pointer to a TerminationCallbackParams_t instance.
120+
* As parameter it expects a pointer to a TerminationCallbackParams_t instance.
121121
*
122122
* @note The object passed in parameter will remain valid for the lifetime
123123
* of the callback. Memory for this object is owned by the BLE_API eventing

features/FEATURE_BLE/ble/DiscoveredCharacteristic.h

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -39,13 +39,13 @@
3939
* Instances of this class are generated by the GattClient discovery procedure
4040
* initiated with GattClient::launchServiceDiscovery().
4141
*
42-
* It expose the main attributes of the discovered characteristic:
42+
* It exposes the main attributes of the discovered characteristic:
4343
* - The UUID of the characteristic, it can be retrieved by a call to the
4444
* function getUUID(). This UUID is the type of the characteristic.
4545
* - Attribute Handles of the characteristic are present as the triplet
4646
* declaration handle, value handle and last handle. The value handle is
4747
* used to read or write the content of the characteristic.
48-
* - The properties contains the set of operations the characteristic can
48+
* - The properties contain the set of operations the characteristic can
4949
* handle, for instance being read or written.
5050
*
5151
* It important to note that the value of the characteristic - if it is
@@ -144,7 +144,7 @@ class DiscoveredCharacteristic {
144144
/**
145145
* Return the value of the broadcast propertie.
146146
*
147-
* @return if true the Server Characteristic Configuration Descriptor
147+
* @return true if the Server Characteristic Configuration Descriptor
148148
* of the characteristic can be configured to broadcast the
149149
* characteristic value during broadcast procedure.
150150
*
@@ -261,8 +261,8 @@ class DiscoveredCharacteristic {
261261
/**
262262
* Not equal to operator for DiscoveredCharacteristic::Properties_t.
263263
*
264-
* @param lhs The right hand side of the expression.
265-
* @param rhs The left hand side of the expression.
264+
* @param lhs The left hand side of the expression.
265+
* @param rhs The right hand side of the expression.
266266
*
267267
* @return true if operands are not equals, false otherwise.
268268
*/
@@ -310,7 +310,7 @@ class DiscoveredCharacteristic {
310310
* - where the read operation begin.
311311
*
312312
* @param[in] onRead Completion callback which will accept the response of
313-
* the read request. The calback is copied, it is not necessary to keep it
313+
* the read request. The callback is copied, it is not necessary to keep it
314314
* in memory after the call.
315315
*
316316
* @return BLE_ERROR_NONE if a read has been initiated.
@@ -492,7 +492,7 @@ class DiscoveredCharacteristic {
492492
/**
493493
* Return the last attribute handle of the characteristic definition.
494494
*
495-
* The attribute layout of a characteristic definition is a follow:
495+
* The attribute layout of a characteristic definition is as follows:
496496
* - Declaration attribute (see #getDeclHandle)
497497
* - Value attribute (see #getValueHandle)
498498
* - Zero or more characteristic descriptors attribute.
@@ -503,7 +503,7 @@ class DiscoveredCharacteristic {
503503
*
504504
* @return The last handle of this characteristic definition.
505505
*
506-
* @note This function is public for informative purposes..
506+
* @note This function is public for informative purposes.
507507
*/
508508
GattAttribute::Handle_t getLastHandle(void) const
509509
{

features/FEATURE_BLE/ble/DiscoveredService.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
*
3535
* GATT Services are discovered on distant GATT servers by the discovery
3636
* procedure which can be initiated by calling
37-
* GattClient::launchServiceDiscovery() or GattClient::discoverServices() . The
37+
* GattClient::launchServiceDiscovery() or GattClient::discoverServices(). The
3838
* discovery process will pass instances of this class to the callback handling
3939
* service discovered.
4040
*

features/FEATURE_BLE/ble/FunctionPointerWithContext.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,12 +36,12 @@
3636
* different even if conceptually they are very similar: Both primitives can be
3737
* copied, called and produce a result.
3838
*
39-
* To solve incompatibilities this class addapt freestanding and member function
39+
* To solve incompatibilities this class adapt freestanding and member function
4040
* to a common interface. The interface chosen is similar to the freestanding
4141
* function pointers interface:
4242
* - Copyable
4343
* - Nullable
44-
* - Callable .
44+
* - Callable
4545
*
4646
* This class also offers a mechanism to chain other instances to it. When an
4747
* instance is called, all the instances being part of the chain are called.
@@ -312,9 +312,9 @@ class FunctionPointerWithContext : public SafeBool<FunctionPointerWithContext<Co
312312
/**
313313
* Factory of adapted member function pointers.
314314
*
315-
* This factory eliminate the need to invoke the qualified constructor of
315+
* This factory eliminates the need to invoke the qualified constructor of
316316
* FunctionPointerWithContext by using automatic type deduction of function
317-
* templates
317+
* templates.
318318
*
319319
* @code
320320
*

features/FEATURE_BLE/ble/Gap.h

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -43,12 +43,12 @@ class GapAdvertisingData;
4343
/**
4444
* Define device discovery, connection and link management procedures.
4545
*
46-
* - Device discovery: A device can advertise nearby peer of its existence,
46+
* - Device discovery: A device can advertise nearby peers of its existence,
4747
* identity and capabilities. Similarly a device can scan its environment to
48-
* find advertising peers. The informations acquired during the scan help to
48+
* find advertising peers. The information acquired during the scan helps to
4949
* identify peers and understand their use. A scanner may acquire more information
50-
* about an advertising peer by sending a scan request. If the peer accept scan
51-
* request it may reply with additional information about its state.
50+
* about an advertising peer by sending a scan request. If the peer accepts scan
51+
* requests it may reply with additional information about its state.
5252
*
5353
* - Connection: A bluetooth device can establish a connection to a connectable
5454
* advertising peer. Once the connection is established both devices can
@@ -75,12 +75,12 @@ class GapAdvertisingData;
7575
*
7676
* @par Advertising
7777
*
78-
* Advertising consist of broadcasting at a regular interval a small amount of
78+
* Advertising consists of broadcasting at a regular interval a small amount of
7979
* data containing valuable informations about the device. These packets may be
8080
* scanned by peer devices listening on BLE advertising channels.
8181
*
82-
* Scanner may also request additional information from a device advertising by
83-
* sending a scan request. If the broadcaster accept scan request it can reply
82+
* Scanners may also request additional information from a device advertising by
83+
* sending a scan request. If the broadcaster accepts scan requests it can reply
8484
* with a scan response packet containing additional information.
8585
*
8686
* @code
@@ -192,7 +192,7 @@ class GapAdvertisingData;
192192
* }
193193
*
194194
* // register connection event handler which will be invoked whether the device
195-
* // act as a central or a peripheral
195+
* // acts as a central or a peripheral
196196
* gap.onConnection(when_connected);
197197
* @endcode
198198
*
@@ -515,7 +515,7 @@ class Gap {
515515
* connection.
516516
*
517517
* It shall be greater than or equal to minConnectionInterval. This
518-
* value is in unit of 1,25ms and shall be in the range [0x0006 : 0x0C80].
518+
* value is in unit of 1.25ms and shall be in the range [0x0006 : 0x0C80].
519519
*/
520520
uint16_t maxConnectionInterval;
521521

@@ -549,7 +549,7 @@ class Gap {
549549
*
550550
* @note broadcaster and scanner roles are not expressed in BLE API.
551551
*
552-
* @important A device can fullfill concurrently different roles.
552+
* @important A device can fullfil different roles concurrently.
553553
*/
554554
enum Role_t {
555555
/**
@@ -1101,7 +1101,7 @@ class Gap {
11011101
* Update connection parameters of an existing connection.
11021102
*
11031103
* In the central role this will initiate a Link Layer connection parameter
1104-
* update procedure. In the peripheral role, this will send the corresponding
1104+
* update procedure. In the peripheral role, this will send the corresponding
11051105
* L2CAP request and wait for the central to perform the procedure.
11061106
*
11071107
* @param[in] handle Connection Handle.
@@ -1263,7 +1263,7 @@ class Gap {
12631263
*
12641264
* @param[in,out] whitelist Define the whitelist instance which will be used
12651265
* to store the whitelist requested. In input memory shall be provisioned by
1266-
* the caller. .
1266+
* the caller.
12671267
*
12681268
* @return BLE_ERROR_NONE if the implementation's whitelist was successfully
12691269
* copied into the supplied reference.
@@ -1485,7 +1485,7 @@ class Gap {
14851485
* A call to this function is equivalent to:
14861486
*
14871487
* @code
1488-
* Gap& gap;
1488+
* Gap &gap;
14891489
*
14901490
* GapAdvertisingData payload = gap.getAdvertisingPayload();
14911491
* payload.addFlags(flags);
@@ -1519,7 +1519,7 @@ class Gap {
15191519
* A call to this function is equivalent to:
15201520
*
15211521
* @code
1522-
* Gap& gap;
1522+
* Gap &gap;
15231523
*
15241524
* GapAdvertisingData payload = gap.getAdvertisingPayload();
15251525
* payload.addAppearance(app);
@@ -1553,7 +1553,7 @@ class Gap {
15531553
* A call to this function is equivalent to:
15541554
*
15551555
* @code
1556-
* Gap& gap;
1556+
* Gap &gap;
15571557
*
15581558
* GapAdvertisingData payload = gap.getAdvertisingPayload();
15591559
* payload.addTxPower(power);
@@ -1587,7 +1587,7 @@ class Gap {
15871587
* A call to this function is equivalent to:
15881588
*
15891589
* @code
1590-
* Gap& gap;
1590+
* Gap &gap;
15911591
*
15921592
* GapAdvertisingData payload = gap.getAdvertisingPayload();
15931593
* payload.addData(type, data, len);
@@ -1630,7 +1630,7 @@ class Gap {
16301630
* A call to this function is equivalent to:
16311631
*
16321632
* @code
1633-
* Gap& gap;
1633+
* Gap &gap;
16341634
*
16351635
* GapAdvertisingData payload = gap.getAdvertisingPayload();
16361636
* payload.updateData(type, data, len);
@@ -1784,8 +1784,8 @@ class Gap {
17841784
/**
17851785
* Set the interval parameter used during scanning procedures.
17861786
*
1787-
* @param[in] interval interval in ms between the start of two consecutive
1788-
* scan window.That value shall be greater or equal to the scan window value.
1787+
* @param[in] interval Interval in ms between the start of two consecutive
1788+
* scan windows. That value shall be greater or equal to the scan window value.
17891789
* The maximum allowed value is 10.24ms.
17901790
*
17911791
* @return BLE_ERROR_NONE if the scan interval was correctly set.

features/FEATURE_BLE/ble/GapAdvertisingData.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@
5353
*
5454
* @code
5555
*
56-
* Gap& gap;
56+
* Gap &gap;
5757
*
5858
* static const uint8_t device_name[] = "HRM";
5959
*

features/FEATURE_BLE/ble/GapAdvertisingParams.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
* - Time interval between advertisement. It can be set at construction time,
3636
* updated by setInterval() and obtained from getInterval().
3737
* - Duration of the advertising process. As others it can be set at
38-
* construction time, modified by setTimeout() retrieved by getTimeout().
38+
* construction time, modified by setTimeout() and retrieved by getTimeout().
3939
*/
4040
class GapAdvertisingParams {
4141
public:

features/FEATURE_BLE/ble/GapScanningParams.h

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,9 @@
2929
*
3030
* The scan procedure is defined by four distinct parameters:
3131
* - Scan window: Period during which the scanner listen to advertising
32-
* channels. That value shall be in the 2.5ms to 10.24s. this value can be
33-
* set at construction time, updated by calling setWindow() and retrieved
34-
* by invoking getWindow().
32+
* channels. That value shall be in the range 2.5ms to 10.24s. This value
33+
* can be set at construction time, updated by calling setWindow() and
34+
* retrieved by invoking getWindow().
3535
*
3636
* - Scan interval: interval between the start of two consecutive scan window.
3737
* That value shall be greater or equal to the scan window value. The
@@ -47,8 +47,8 @@
4747
* or connectable advertiser. Advertisers may respond to the scan request
4848
* by a scan response containing the scan response payload. If not set then
4949
* the scanner does not send any request. This flag is set at construction
50-
* time, may be updated with the help of setActiveScanning() and get by
51-
* getActiveScanning().
50+
* time, may be updated with the help of setActiveScanning() and retrieved
51+
* by getActiveScanning().
5252
*
5353
* @note If the scan windows duration is equal to the scan interval then the
5454
* device should listen continuously during the scan procedure.

features/FEATURE_BLE/ble/GattCallbackParamTypes.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@
3232
* received a write response.
3333
*
3434
* @important The fields offset, len and data are only populated by the
35-
* GattServer when it receive a write request. Those fields shall not be used
36-
* by callbacks attached to the GattClient.
35+
* GattServer when it has received a write request. Those fields shall not be
36+
* used by callbacks attached to the GattClient.
3737
*
3838
* @important The fields status and error_code are only populated by the
3939
* GattClient when it has received a write response. Those fields shall not be

0 commit comments

Comments
 (0)