5.4.4.1 Query as Client by Handle (QCH,<hex16>[,<hex16>,<hex16>])
Format:
(QCH,<hex16>[,<hex16>,<hex16>])
The command QCH reads the content of the GATT service characteristic on
the remote device by addressing its handle.
Command QCH takes three parameters. The first parameter indicates the handle
value (16-bit hex value) of the characteristic in a particular server service. The
second parameter is a 16-bit hex value that indicates the Bluetooth Low Energy link
connection handle. The user must find a match between the handle and its characteristic
UUID by using the command LC.
This command is effective under the following conditions:
- An active connection with peer exists.
- The command
CIstarts the client operation. - The handle parameter is valid and the corresponding characteristic is readable according to its property.
The value returned is retrieved from the remote peer device.
| Example: | QCH,001A,0071
|
// Read the content of the characteristic with the handle 0x001A from the remote device, and the connection handle is 0x0071 |
| Response: | <Value read>
| // Success |
Err |
// Syntax error, invalid parameter, not connected or characteristic not readable | |
%ERR_READ% | // Status string |
