Merge pull request #832 from mabuch/fix-doc-motionservice-uuid
fix Motion Service UUID in doc and code comments
This commit is contained in:
commit
e8eee76b48
2 changed files with 5 additions and 5 deletions
|
@ -3,13 +3,13 @@
|
||||||
The motion service exposes step count and raw X/Y/Z motion value as READ and NOTIFY characteristics.
|
The motion service exposes step count and raw X/Y/Z motion value as READ and NOTIFY characteristics.
|
||||||
|
|
||||||
## Service
|
## Service
|
||||||
The service UUID is **00020000-78fc-48fe-8e23-433b3a1942d0**
|
The service UUID is **00030000-78fc-48fe-8e23-433b3a1942d0**
|
||||||
|
|
||||||
## Characteristics
|
## Characteristics
|
||||||
### Step count (UUID 00020001-78fc-48fe-8e23-433b3a1942d0)
|
### Step count (UUID 00030001-78fc-48fe-8e23-433b3a1942d0)
|
||||||
The current number of steps represented as a single `uint32_t` (4 bytes) value.
|
The current number of steps represented as a single `uint32_t` (4 bytes) value.
|
||||||
|
|
||||||
### Raw motion values (UUID 00020002-78fc-48fe-8e23-433b3a1942d0)
|
### Raw motion values (UUID 00030002-78fc-48fe-8e23-433b3a1942d0)
|
||||||
The current raw motion values. This is a 3 `int16_t` array:
|
The current raw motion values. This is a 3 `int16_t` array:
|
||||||
|
|
||||||
- [0] : X
|
- [0] : X
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
using namespace Pinetime::Controllers;
|
using namespace Pinetime::Controllers;
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
// 0002yyxx-78fc-48fe-8e23-433b3a1942d0
|
// 0003yyxx-78fc-48fe-8e23-433b3a1942d0
|
||||||
constexpr ble_uuid128_t CharUuid(uint8_t x, uint8_t y) {
|
constexpr ble_uuid128_t CharUuid(uint8_t x, uint8_t y) {
|
||||||
return ble_uuid128_t{
|
return ble_uuid128_t{
|
||||||
.u = {.type = BLE_UUID_TYPE_128},
|
.u = {.type = BLE_UUID_TYPE_128},
|
||||||
|
@ -13,7 +13,7 @@ namespace {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
// 00020000-78fc-48fe-8e23-433b3a1942d0
|
// 00030000-78fc-48fe-8e23-433b3a1942d0
|
||||||
constexpr ble_uuid128_t BaseUuid() {
|
constexpr ble_uuid128_t BaseUuid() {
|
||||||
return CharUuid(0x00, 0x00);
|
return CharUuid(0x00, 0x00);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue