BLE: Update documentation.

Fix typos, spelling and conjugation.
pull/5392/head
Vincent Coubard 2017-10-30 15:37:59 +00:00
parent 67b47cad87
commit 3c3592a9d3
16 changed files with 87 additions and 87 deletions

View File

@ -89,8 +89,8 @@ public:
/** /**
* Start the initialization of the vendor BLE subsystem. * Start the initialization of the vendor BLE subsystem.
* *
* Call to this function is initiated by BLE::init, instanceID identify the * Calls to this function are initiated by BLE::init, instanceID identify
* BLE instance which issue that call while the initCallback is used to * the BLE instance which issue that call while the initCallback is used to
* signal asynchronously the completion of the initialization process. * signal asynchronously the completion of the initialization process.
* *
* @param[in] instanceID Identifier of the BLE instance requesting * @param[in] instanceID Identifier of the BLE instance requesting
@ -166,7 +166,8 @@ public:
/** /**
* Accessor to the vendor implementation of the Gap interface. * Accessor to the vendor implementation of the Gap interface.
* *
* @return A reference to a Gap object associated to this BLE instance. * @return A reference to a Gap object associated to this BLEInstanceBase
* instance.
* *
* @see BLE::gap() Gap * @see BLE::gap() Gap
*/ */
@ -254,7 +255,7 @@ private:
* Return the instance of the vendor implementation of BLEInstanceBase. * Return the instance of the vendor implementation of BLEInstanceBase.
* *
* @important Contrary to its name, this function does not return a new instance * @important Contrary to its name, this function does not return a new instance
* at eachcall. It rather act like an accessor to a singleton. * at each call. It rather act like an accessor to a singleton.
* *
* @important An implementation for this function must be provided by the vendor * @important An implementation for this function must be provided by the vendor
* library, otherwise there will be a linker error. * library, otherwise there will be a linker error.

View File

@ -30,7 +30,7 @@
namespace ble { namespace ble {
/** /**
* Opaque reference to a connection * Opaque reference to a connection.
* *
* Internally a connection handle is an unsigned integer capable of holding a * Internally a connection handle is an unsigned integer capable of holding a
* pointer. * pointer.
@ -67,7 +67,7 @@ struct attribute_handle_range_t {
* Equal operator for attribute_handle_range_t. * Equal operator for attribute_handle_range_t.
* *
* @param[in] lhs Left hand side of the expression. * @param[in] lhs Left hand side of the expression.
* @param[in] rhs Left hand side of the expression. * @param[in] rhs Right hand side of the expression.
* *
* @return true if lhs is equal to rhs and false otherwise. * @return true if lhs is equal to rhs and false otherwise.
*/ */
@ -81,7 +81,7 @@ struct attribute_handle_range_t {
* Not equal operator for attribute_handle_range_t. * Not equal operator for attribute_handle_range_t.
* *
* @param[in] lhs Left hand side of the expression. * @param[in] lhs Left hand side of the expression.
* @param[in] rhs Left hand side of the expression. * @param[in] rhs Right hand side of the expression.
* *
* @return true if lhs is not equal to rhs and false otherwise. * @return true if lhs is not equal to rhs and false otherwise.
*/ */

View File

@ -72,7 +72,7 @@
* } * }
* @endcode * @endcode
* *
* @note memory allocation is used to add new function like object into the * @note memory allocation is used to add new function like objects into the
* call chain. * call chain.
* *
* @tparam ContextType Type of the parameter accepted by the callbacks hosted * @tparam ContextType Type of the parameter accepted by the callbacks hosted
@ -270,11 +270,11 @@ public:
* @code * @code
* CallChainOfFunctionPointersWithContext<void *> chain; * CallChainOfFunctionPointersWithContext<void *> chain;
* *
* if (chain) { * if (!chain) {
* // Do something if the chain is empty. * // Do something if the chain is empty.
* } * }
* *
* if (!chain) { * if (chain) {
* // Do something if the chain is not empty. * // Do something if the chain is not empty.
* } * }
* @endcode * @endcode

View File

@ -100,7 +100,7 @@ public:
/** /**
* Characteristic descriptor discovered event handler. * Characteristic descriptor discovered event handler.
* *
* As parameter it expect a pointer to a DiscoveryCallbackParams_t instance. * As parameter it expects a pointer to a DiscoveryCallbackParams_t instance.
* *
* @note The object passed in parameter will remain valid for the lifetime * @note The object passed in parameter will remain valid for the lifetime
* of the callback. Memory for this object is owned by the BLE_API eventing * of the callback. Memory for this object is owned by the BLE_API eventing
@ -117,7 +117,7 @@ public:
/** /**
* Handler of Characteristic descriptor discovery ended event. * Handler of Characteristic descriptor discovery ended event.
* *
* As parameter it expect a pointer to a TerminationCallbackParams_t instance. * As parameter it expects a pointer to a TerminationCallbackParams_t instance.
* *
* @note The object passed in parameter will remain valid for the lifetime * @note The object passed in parameter will remain valid for the lifetime
* of the callback. Memory for this object is owned by the BLE_API eventing * of the callback. Memory for this object is owned by the BLE_API eventing

View File

@ -39,13 +39,13 @@
* Instances of this class are generated by the GattClient discovery procedure * Instances of this class are generated by the GattClient discovery procedure
* initiated with GattClient::launchServiceDiscovery(). * initiated with GattClient::launchServiceDiscovery().
* *
* It expose the main attributes of the discovered characteristic: * It exposes the main attributes of the discovered characteristic:
* - The UUID of the characteristic, it can be retrieved by a call to the * - The UUID of the characteristic, it can be retrieved by a call to the
* function getUUID(). This UUID is the type of the characteristic. * function getUUID(). This UUID is the type of the characteristic.
* - Attribute Handles of the characteristic are present as the triplet * - Attribute Handles of the characteristic are present as the triplet
* declaration handle, value handle and last handle. The value handle is * declaration handle, value handle and last handle. The value handle is
* used to read or write the content of the characteristic. * used to read or write the content of the characteristic.
* - The properties contains the set of operations the characteristic can * - The properties contain the set of operations the characteristic can
* handle, for instance being read or written. * handle, for instance being read or written.
* *
* It important to note that the value of the characteristic - if it is * It important to note that the value of the characteristic - if it is
@ -144,7 +144,7 @@ public:
/** /**
* Return the value of the broadcast propertie. * Return the value of the broadcast propertie.
* *
* @return if true the Server Characteristic Configuration Descriptor * @return true if the Server Characteristic Configuration Descriptor
* of the characteristic can be configured to broadcast the * of the characteristic can be configured to broadcast the
* characteristic value during broadcast procedure. * characteristic value during broadcast procedure.
* *
@ -261,8 +261,8 @@ public:
/** /**
* Not equal to operator for DiscoveredCharacteristic::Properties_t. * Not equal to operator for DiscoveredCharacteristic::Properties_t.
* *
* @param lhs The right hand side of the expression. * @param lhs The left hand side of the expression.
* @param rhs The left hand side of the expression. * @param rhs The right hand side of the expression.
* *
* @return true if operands are not equals, false otherwise. * @return true if operands are not equals, false otherwise.
*/ */
@ -310,7 +310,7 @@ public:
* - where the read operation begin. * - where the read operation begin.
* *
* @param[in] onRead Completion callback which will accept the response of * @param[in] onRead Completion callback which will accept the response of
* the read request. The calback is copied, it is not necessary to keep it * the read request. The callback is copied, it is not necessary to keep it
* in memory after the call. * in memory after the call.
* *
* @return BLE_ERROR_NONE if a read has been initiated. * @return BLE_ERROR_NONE if a read has been initiated.
@ -492,7 +492,7 @@ public:
/** /**
* Return the last attribute handle of the characteristic definition. * Return the last attribute handle of the characteristic definition.
* *
* The attribute layout of a characteristic definition is a follow: * The attribute layout of a characteristic definition is as follows:
* - Declaration attribute (see #getDeclHandle) * - Declaration attribute (see #getDeclHandle)
* - Value attribute (see #getValueHandle) * - Value attribute (see #getValueHandle)
* - Zero or more characteristic descriptors attribute. * - Zero or more characteristic descriptors attribute.
@ -503,7 +503,7 @@ public:
* *
* @return The last handle of this characteristic definition. * @return The last handle of this characteristic definition.
* *
* @note This function is public for informative purposes.. * @note This function is public for informative purposes.
*/ */
GattAttribute::Handle_t getLastHandle(void) const GattAttribute::Handle_t getLastHandle(void) const
{ {

View File

@ -34,7 +34,7 @@
* *
* GATT Services are discovered on distant GATT servers by the discovery * GATT Services are discovered on distant GATT servers by the discovery
* procedure which can be initiated by calling * procedure which can be initiated by calling
* GattClient::launchServiceDiscovery() or GattClient::discoverServices() . The * GattClient::launchServiceDiscovery() or GattClient::discoverServices(). The
* discovery process will pass instances of this class to the callback handling * discovery process will pass instances of this class to the callback handling
* service discovered. * service discovered.
* *

View File

@ -36,12 +36,12 @@
* different even if conceptually they are very similar: Both primitives can be * different even if conceptually they are very similar: Both primitives can be
* copied, called and produce a result. * copied, called and produce a result.
* *
* To solve incompatibilities this class addapt freestanding and member function * To solve incompatibilities this class adapt freestanding and member function
* to a common interface. The interface chosen is similar to the freestanding * to a common interface. The interface chosen is similar to the freestanding
* function pointers interface: * function pointers interface:
* - Copyable * - Copyable
* - Nullable * - Nullable
* - Callable . * - Callable
* *
* This class also offers a mechanism to chain other instances to it. When an * This class also offers a mechanism to chain other instances to it. When an
* instance is called, all the instances being part of the chain are called. * instance is called, all the instances being part of the chain are called.
@ -312,9 +312,9 @@ private:
/** /**
* Factory of adapted member function pointers. * Factory of adapted member function pointers.
* *
* This factory eliminate the need to invoke the qualified constructor of * This factory eliminates the need to invoke the qualified constructor of
* FunctionPointerWithContext by using automatic type deduction of function * FunctionPointerWithContext by using automatic type deduction of function
* templates * templates.
* *
* @code * @code
* *

View File

@ -43,12 +43,12 @@ class GapAdvertisingData;
/** /**
* Define device discovery, connection and link management procedures. * Define device discovery, connection and link management procedures.
* *
* - Device discovery: A device can advertise nearby peer of its existence, * - Device discovery: A device can advertise nearby peers of its existence,
* identity and capabilities. Similarly a device can scan its environment to * identity and capabilities. Similarly a device can scan its environment to
* find advertising peers. The informations acquired during the scan help to * find advertising peers. The information acquired during the scan helps to
* identify peers and understand their use. A scanner may acquire more information * identify peers and understand their use. A scanner may acquire more information
* about an advertising peer by sending a scan request. If the peer accept scan * about an advertising peer by sending a scan request. If the peer accepts scan
* request it may reply with additional information about its state. * requests it may reply with additional information about its state.
* *
* - Connection: A bluetooth device can establish a connection to a connectable * - Connection: A bluetooth device can establish a connection to a connectable
* advertising peer. Once the connection is established both devices can * advertising peer. Once the connection is established both devices can
@ -75,12 +75,12 @@ class GapAdvertisingData;
* *
* @par Advertising * @par Advertising
* *
* Advertising consist of broadcasting at a regular interval a small amount of * Advertising consists of broadcasting at a regular interval a small amount of
* data containing valuable informations about the device. These packets may be * data containing valuable informations about the device. These packets may be
* scanned by peer devices listening on BLE advertising channels. * scanned by peer devices listening on BLE advertising channels.
* *
* Scanner may also request additional information from a device advertising by * Scanners may also request additional information from a device advertising by
* sending a scan request. If the broadcaster accept scan request it can reply * sending a scan request. If the broadcaster accepts scan requests it can reply
* with a scan response packet containing additional information. * with a scan response packet containing additional information.
* *
* @code * @code
@ -192,7 +192,7 @@ class GapAdvertisingData;
* } * }
* *
* // register connection event handler which will be invoked whether the device * // register connection event handler which will be invoked whether the device
* // act as a central or a peripheral * // acts as a central or a peripheral
* gap.onConnection(when_connected); * gap.onConnection(when_connected);
* @endcode * @endcode
* *
@ -515,7 +515,7 @@ public:
* connection. * connection.
* *
* It shall be greater than or equal to minConnectionInterval. This * It shall be greater than or equal to minConnectionInterval. This
* value is in unit of 1,25ms and shall be in the range [0x0006 : 0x0C80]. * value is in unit of 1.25ms and shall be in the range [0x0006 : 0x0C80].
*/ */
uint16_t maxConnectionInterval; uint16_t maxConnectionInterval;
@ -549,7 +549,7 @@ public:
* *
* @note broadcaster and scanner roles are not expressed in BLE API. * @note broadcaster and scanner roles are not expressed in BLE API.
* *
* @important A device can fullfill concurrently different roles. * @important A device can fullfil different roles concurrently.
*/ */
enum Role_t { enum Role_t {
/** /**
@ -1263,7 +1263,7 @@ public:
* *
* @param[in,out] whitelist Define the whitelist instance which will be used * @param[in,out] whitelist Define the whitelist instance which will be used
* to store the whitelist requested. In input memory shall be provisioned by * to store the whitelist requested. In input memory shall be provisioned by
* the caller. . * the caller.
* *
* @return BLE_ERROR_NONE if the implementation's whitelist was successfully * @return BLE_ERROR_NONE if the implementation's whitelist was successfully
* copied into the supplied reference. * copied into the supplied reference.
@ -1485,7 +1485,7 @@ public:
* A call to this function is equivalent to: * A call to this function is equivalent to:
* *
* @code * @code
* Gap& gap; * Gap &gap;
* *
* GapAdvertisingData payload = gap.getAdvertisingPayload(); * GapAdvertisingData payload = gap.getAdvertisingPayload();
* payload.addFlags(flags); * payload.addFlags(flags);
@ -1519,7 +1519,7 @@ public:
* A call to this function is equivalent to: * A call to this function is equivalent to:
* *
* @code * @code
* Gap& gap; * Gap &gap;
* *
* GapAdvertisingData payload = gap.getAdvertisingPayload(); * GapAdvertisingData payload = gap.getAdvertisingPayload();
* payload.addAppearance(app); * payload.addAppearance(app);
@ -1553,7 +1553,7 @@ public:
* A call to this function is equivalent to: * A call to this function is equivalent to:
* *
* @code * @code
* Gap& gap; * Gap &gap;
* *
* GapAdvertisingData payload = gap.getAdvertisingPayload(); * GapAdvertisingData payload = gap.getAdvertisingPayload();
* payload.addTxPower(power); * payload.addTxPower(power);
@ -1587,7 +1587,7 @@ public:
* A call to this function is equivalent to: * A call to this function is equivalent to:
* *
* @code * @code
* Gap& gap; * Gap &gap;
* *
* GapAdvertisingData payload = gap.getAdvertisingPayload(); * GapAdvertisingData payload = gap.getAdvertisingPayload();
* payload.addData(type, data, len); * payload.addData(type, data, len);
@ -1630,7 +1630,7 @@ public:
* A call to this function is equivalent to: * A call to this function is equivalent to:
* *
* @code * @code
* Gap& gap; * Gap &gap;
* *
* GapAdvertisingData payload = gap.getAdvertisingPayload(); * GapAdvertisingData payload = gap.getAdvertisingPayload();
* payload.updateData(type, data, len); * payload.updateData(type, data, len);
@ -1784,8 +1784,8 @@ public:
/** /**
* Set the interval parameter used during scanning procedures. * Set the interval parameter used during scanning procedures.
* *
* @param[in] interval interval in ms between the start of two consecutive * @param[in] interval Interval in ms between the start of two consecutive
* scan window.That value shall be greater or equal to the scan window value. * scan windows. That value shall be greater or equal to the scan window value.
* The maximum allowed value is 10.24ms. * The maximum allowed value is 10.24ms.
* *
* @return BLE_ERROR_NONE if the scan interval was correctly set. * @return BLE_ERROR_NONE if the scan interval was correctly set.

View File

@ -53,7 +53,7 @@
* *
* @code * @code
* *
* Gap& gap; * Gap &gap;
* *
* static const uint8_t device_name[] = "HRM"; * static const uint8_t device_name[] = "HRM";
* *

View File

@ -35,7 +35,7 @@
* - Time interval between advertisement. It can be set at construction time, * - Time interval between advertisement. It can be set at construction time,
* updated by setInterval() and obtained from getInterval(). * updated by setInterval() and obtained from getInterval().
* - Duration of the advertising process. As others it can be set at * - Duration of the advertising process. As others it can be set at
* construction time, modified by setTimeout() retrieved by getTimeout(). * construction time, modified by setTimeout() and retrieved by getTimeout().
*/ */
class GapAdvertisingParams { class GapAdvertisingParams {
public: public:

View File

@ -29,9 +29,9 @@
* *
* The scan procedure is defined by four distinct parameters: * The scan procedure is defined by four distinct parameters:
* - Scan window: Period during which the scanner listen to advertising * - Scan window: Period during which the scanner listen to advertising
* channels. That value shall be in the 2.5ms to 10.24s. this value can be * channels. That value shall be in the range 2.5ms to 10.24s. This value
* set at construction time, updated by calling setWindow() and retrieved * can be set at construction time, updated by calling setWindow() and
* by invoking getWindow(). * retrieved by invoking getWindow().
* *
* - Scan interval: interval between the start of two consecutive scan window. * - Scan interval: interval between the start of two consecutive scan window.
* That value shall be greater or equal to the scan window value. The * That value shall be greater or equal to the scan window value. The
@ -47,8 +47,8 @@
* or connectable advertiser. Advertisers may respond to the scan request * or connectable advertiser. Advertisers may respond to the scan request
* by a scan response containing the scan response payload. If not set then * by a scan response containing the scan response payload. If not set then
* the scanner does not send any request. This flag is set at construction * the scanner does not send any request. This flag is set at construction
* time, may be updated with the help of setActiveScanning() and get by * time, may be updated with the help of setActiveScanning() and retrieved
* getActiveScanning(). * by getActiveScanning().
* *
* @note If the scan windows duration is equal to the scan interval then the * @note If the scan windows duration is equal to the scan interval then the
* device should listen continuously during the scan procedure. * device should listen continuously during the scan procedure.

View File

@ -32,8 +32,8 @@
* received a write response. * received a write response.
* *
* @important The fields offset, len and data are only populated by the * @important The fields offset, len and data are only populated by the
* GattServer when it receive a write request. Those fields shall not be used * GattServer when it has received a write request. Those fields shall not be
* by callbacks attached to the GattClient. * used by callbacks attached to the GattClient.
* *
* @important The fields status and error_code are only populated by the * @important The fields status and error_code are only populated by the
* GattClient when it has received a write response. Those fields shall not be * GattClient when it has received a write response. Those fields shall not be

View File

@ -43,7 +43,7 @@
* A GATT server host a fixed set of services. These services are a logical * A GATT server host a fixed set of services. These services are a logical
* composition of Characteristic which may be discovered, read, written or also * composition of Characteristic which may be discovered, read, written or also
* broadcast their state to a connected client. These characteristics may also * broadcast their state to a connected client. These characteristics may also
* contain meta informations named characteristic descriptor. A characteristic * contain meta information named characteristic descriptors. A characteristic
* descriptor may be used to indicate the unit used for a characteristic value, * descriptor may be used to indicate the unit used for a characteristic value,
* describe in a textual form the characterisic purpose or allow a client to * describe in a textual form the characterisic purpose or allow a client to
* register for notification of updates of the characteristic value. * register for notification of updates of the characteristic value.
@ -62,8 +62,8 @@
* (acquired during discovery) a client can read or write the value of a given * (acquired during discovery) a client can read or write the value of a given
* characteristic. * characteristic.
* *
* mbed BLE abstract most read/write operation to offer a user a single API which * mbed BLE abstract most read and write operation to offer a single API which
* can be use to read or write characteristics values. Application code do not * can be used to read or write characteristics values. Application code does not
* have to handle the fragmentation/reassembly process necessary if the attribute * have to handle the fragmentation/reassembly process necessary if the attribute
* value to transported cannot fit in a single data packet. * value to transported cannot fit in a single data packet.
* *
@ -73,7 +73,7 @@
* register to notification or indication from the characteristic. When the * register to notification or indication from the characteristic. When the
* characteristic value is updated by the server, the server can forward the * characteristic value is updated by the server, the server can forward the
* new value to the registered clients. The notification/indication mechanism * new value to the registered clients. The notification/indication mechanism
* prevents polling from the client and therefore minimize the transactons * prevents polling from the client and therefore minimize the transactions
* involved between a client and a server. * involved between a client and a server.
* *
* Registration is made by writing the Client Characteristic Configuration * Registration is made by writing the Client Characteristic Configuration
@ -112,7 +112,7 @@ public:
/** /**
* Write command. * Write command.
* *
* It is is used to request the server to write the value of an attribute. * It is used to request the server to write the value of an attribute.
* The server does not acknowledge the status of the operation. * The server does not acknowledge the status of the operation.
*/ */
GATT_OP_WRITE_CMD = 0x02, GATT_OP_WRITE_CMD = 0x02,
@ -199,14 +199,14 @@ public:
* @param[in] cc Characteristic discovered event handler invoked when a * @param[in] cc Characteristic discovered event handler invoked when a
* matching characteristic has been found. This parameter may be NULL. * matching characteristic has been found. This parameter may be NULL.
* @param[in] matchingServiceUUID UUID of the service the caller is * @param[in] matchingServiceUUID UUID of the service the caller is
* interrested in. If a service discovered match this filter then @p sc is * interested in. If a service discovered matches this filter then @p sc is
* invoked with it. The special value BLE_UUID_UNKNOWN act is a wildcard * invoked with it. The special value BLE_UUID_UNKNOWN act as a wildcard
* which can be used to discover all services present on the peer GATT * which can be used to discover all services present on the peer GATT
* server. * server.
* @param[in] matchingCharacteristicUUIDIn UUID of the characteristic the * @param[in] matchingCharacteristicUUIDIn UUID of the characteristic the
* caller is interrested in. If a characteristic discovered match this * caller is interested in. If a characteristic discovered matches this
* filter then @p cc is invoked with it. The special value BLE_UUID_UNKNOWN * filter then @p cc is invoked with it. The special value BLE_UUID_UNKNOWN
* act is a wildcard which can be used to discover all services present on * act as a wildcard which can be used to discover all services present on
* the peer GATT server. * the peer GATT server.
* *
* @par Discovery procedure implementation detail * @par Discovery procedure implementation detail
@ -265,7 +265,7 @@ public:
* @param[in] callback Service discovered event handler invoked when a * @param[in] callback Service discovered event handler invoked when a
* matching service has been discovered. This parameter may be NULL. * matching service has been discovered. This parameter may be NULL.
* @param[in] matchingServiceUUID UUID of the service the caller is * @param[in] matchingServiceUUID UUID of the service the caller is
* interrested in. If a service discovered match this filter then @p sc is * interested in. If a service discovered match this filter then @p sc is
* invoked with it. The special value BLE_UUID_UNKNOWN act is a wildcard * invoked with it. The special value BLE_UUID_UNKNOWN act is a wildcard
* which can be used to discover all services present on the peer GATT * which can be used to discover all services present on the peer GATT
* server. * server.
@ -346,7 +346,7 @@ public:
/** /**
* Terminate all ongoing service discovery procedures. * Terminate all ongoing service discovery procedures.
* *
* It result in an invocation of the service discovery termination handler * It results in an invocation of the service discovery termination handler
* registered with onServiceDiscoveryTermination(). * registered with onServiceDiscoveryTermination().
*/ */
virtual void terminateServiceDiscovery(void) virtual void terminateServiceDiscovery(void)
@ -358,9 +358,9 @@ public:
/** /**
* Initiate the read procedure of an attribute handle. * Initiate the read procedure of an attribute handle.
* *
* Once the attribute value has been read in its entirety the process issue * Once the attribute value has been read in its entirety the process issues
* an attribute read event and pass it to all events handlers registered by * an attribute read event and passes it to all events handlers registered
* onDataRead. * by onDataRead.
* *
* @param[in] connHandle Handle of the connection used to send the read * @param[in] connHandle Handle of the connection used to send the read
* request. * request.
@ -381,8 +381,8 @@ public:
* *
* While the attribute data in the response are MTU - 1 long: * While the attribute data in the response are MTU - 1 long:
* - Concat the response to the value containing the previous responses. * - Concat the response to the value containing the previous responses.
* - Increment the value of the offset by MTU - 1 . * - Increment the value of the offset by MTU - 1.
* - send a read blob request with the updated offset. * - Send a read blob request with the updated offset.
* *
* Finally concat the last response with the value containing all the * Finally concat the last response with the value containing all the
* previous responses and forward that value to the event handlers. * previous responses and forward that value to the event handlers.
@ -409,7 +409,7 @@ public:
* is reported to the event handlers registered via onDataWritten(). * is reported to the event handlers registered via onDataWritten().
* *
* @param[in] cmd Type of the write procedure used. If GATT_OP_WRITE_CMD * @param[in] cmd Type of the write procedure used. If GATT_OP_WRITE_CMD
* is set then value length shall be not be greater than the size of the mtu * is set then value length shall not be greater than the size of the mtu
* of connHandle minus three. * of connHandle minus three.
* @param[in] connHandle Handle of the connection used to send the write * @param[in] connHandle Handle of the connection used to send the write
* request or command. * request or command.
@ -423,17 +423,17 @@ public:
* *
* If the operation is a write command then an implementation shall use the * If the operation is a write command then an implementation shall use the
* GATT write without response procedure and an error shall be returned if * GATT write without response procedure and an error shall be returned if
* the data buffer to write is larger than the size of the . * the data buffer to write is larger than the size of the MTU - 3.
* *
* If the operation is a write command and the size of the data buffer to * If the operation is a write command and the size of the data buffer to
* write is less than than the size of the MTU - 3 then the ATT write request * write is less than than the size of the MTU - 3 then the ATT write request
* procedure shall be used and the response shall be reported to the handlers * procedure shall be used and the response shall be reported to the handlers
* listening for write response. * listening for write response.
* *
* Otherwise the data buffer to write shall be divided in chunk with a * Otherwise the data buffer to write shall be divided in chunks with a
* maximum size of MTU - 5. Those chunks shall be sent sequentially to the * maximum size of MTU - 5. Those chunks shall be sent sequentially to the
* peer in ATT prepare write requests. If an error response is received * peer in ATT prepare write requests. If an error response is received
* during the process, the procedure shall ends immediately, the prepared * during the process, the procedure shall end immediately, the prepared
* write discarded and an error shall be reported to the application handlers. * write discarded and an error shall be reported to the application handlers.
* Once all the chunks have been sent, the transaction shall be completed * Once all the chunks have been sent, the transaction shall be completed
* by sending an execute write request to the peer. The peer response shall * by sending an execute write request to the peer. The peer response shall
@ -559,12 +559,12 @@ public:
* Initiate the descriptor discovery procedure for a given characteristic. * Initiate the descriptor discovery procedure for a given characteristic.
* *
* When a descriptor is discovered the discovered descriptor is forwarded * When a descriptor is discovered the discovered descriptor is forwarded
* to @p discoveryCallback. After the discovery of all the descriptor, the * to @p discoveryCallback. After the discovery of all the descriptors, the
* procedure ends and send a descriptor discovery termination event to @p * procedure ends and send a descriptor discovery termination event to @p
* termination callback. * termination callback.
* *
* Application code may monitor the discovery process by querying its status * Application code may monitor the discovery process by querying its status
* with isCharacteristicDescriptorDiscoveryActive(). It can also ends the * with isCharacteristicDescriptorDiscoveryActive(). It can also end the
* discovery process by calling terminateCharacteristicDescriptorDiscovery(). * discovery process by calling terminateCharacteristicDescriptorDiscovery().
* *
* @param[in] characteristic The characteristic owning the descriptors to * @param[in] characteristic The characteristic owning the descriptors to
@ -575,7 +575,7 @@ public:
* event of the procedure. * event of the procedure.
* *
* @return BLE_ERROR_NONE if the characteristic descriptor discovery * @return BLE_ERROR_NONE if the characteristic descriptor discovery
* procedureis has been launched successfully otherwise an appropriate error. * procedure has been launched successfully otherwise an appropriate error.
*/ */
virtual ble_error_t discoverCharacteristicDescriptors( virtual ble_error_t discoverCharacteristicDescriptors(
const DiscoveredCharacteristic& characteristic, const DiscoveredCharacteristic& characteristic,

View File

@ -64,8 +64,8 @@ protected:
/** /**
* Safe conversion of objects in boolean context. * Safe conversion of objects in boolean context.
* *
* Classes wanting to evaluation of their instances in boolean context must * Classes wanting evaluation of their instances in boolean context must derive
* derive publicly from this class rather than implementing the easy to misuse * publicly from this class rather than implementing the easy to misuse
* operator bool(). * operator bool().
* *
* Descendant classes must implement the function bool toBool() const to enable * Descendant classes must implement the function bool toBool() const to enable

View File

@ -62,10 +62,10 @@ static uint8_t char2int(char c)
* 0000xxxx-0000-1000-8000-00805F9B34FB where xxxx is the 16 bit UUID. * 0000xxxx-0000-1000-8000-00805F9B34FB where xxxx is the 16 bit UUID.
* Values of those UUIDs are defined by the Bluetooth body. The short * Values of those UUIDs are defined by the Bluetooth body. The short
* representation save bandwidth during protocol transactions. * representation save bandwidth during protocol transactions.
* - 128 bits UUIDs: Complete representation of an UUID. They are comonly used * - 128 bits UUIDs: Complete representation of an UUID. They are commonly
* for user defined UUID. * used for user defined UUID.
* *
* This class act as an addapter over these two kind of UUIDs to allow * This class act as an adapter over these two kind of UUIDs to allow
* indiscriminate usage of both forms in mbed BLE APIs . * indiscriminate usage of both forms in mbed BLE APIs .
* *
* @note 32 bits UUID representation is not supported at the current moment. * @note 32 bits UUID representation is not supported at the current moment.
@ -132,14 +132,13 @@ public:
public: public:
/** /**
* construct a 128-bit UUID from a string. * Construct a 128-bit UUID from a string.
* *
* @param[in] stringUUID Human readable representation of the UUID following * @param[in] stringUUID Human readable representation of the UUID following
* the format XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX. * the format XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX.
* *
* @note Upper and lower case are supported. * @note Upper and lower case are supported.
* @note Hyphens are optional and the string must at most includes up to four * @note Hyphens are optional. The string must include at most four hyphens.
* of them.
* *
* @note Internally the UUID is stored in the little endian order as a 16 * @note Internally the UUID is stored in the little endian order as a 16
* byte array. * byte array.
@ -212,7 +211,7 @@ public:
* @param[in] _shortUUID 16 bit part of the standard UUID. * @param[in] _shortUUID 16 bit part of the standard UUID.
* The short UUID value. * The short UUID value.
* *
* @note User defined UUID are comonly named vendor-specific UUIDs accross * @note User defined UUID are commonly named vendor-specific UUIDs across
* the Bluetooth literature. * the Bluetooth literature.
*/ */
UUID(ShortUUIDBytes_t _shortUUID) : UUID(ShortUUIDBytes_t _shortUUID) :
@ -346,7 +345,7 @@ public:
* *
* @param[in] other The UUID compared to this. * @param[in] other The UUID compared to this.
* *
* @return true if both UUIDs are equal and false otherwise. * @return true if both UUIDs are not equal and false otherwise.
*/ */
bool operator!= (const UUID &other) const bool operator!= (const UUID &other) const
{ {