Motion service : fix step notifications that were sent as a single byte instead of 4 (uint32_t).
This commit is contained in:
parent
82ca526ec2
commit
71ce13d309
|
@ -80,7 +80,7 @@ int MotionService::OnStepCountRequested(uint16_t connectionHandle, uint16_t attr
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
void MotionService::OnNewStepCountValue(uint8_t stepCount) {
|
void MotionService::OnNewStepCountValue(uint32_t stepCount) {
|
||||||
if(!stepCountNoficationEnabled) return;
|
if(!stepCountNoficationEnabled) return;
|
||||||
|
|
||||||
uint32_t buffer = stepCount;
|
uint32_t buffer = stepCount;
|
||||||
|
|
|
@ -17,7 +17,7 @@ namespace Pinetime {
|
||||||
MotionService(Pinetime::System::SystemTask& system, Controllers::MotionController& motionController);
|
MotionService(Pinetime::System::SystemTask& system, Controllers::MotionController& motionController);
|
||||||
void Init();
|
void Init();
|
||||||
int OnStepCountRequested(uint16_t connectionHandle, uint16_t attributeHandle, ble_gatt_access_ctxt* context);
|
int OnStepCountRequested(uint16_t connectionHandle, uint16_t attributeHandle, ble_gatt_access_ctxt* context);
|
||||||
void OnNewStepCountValue(uint8_t stepCount);
|
void OnNewStepCountValue(uint32_t stepCount);
|
||||||
void OnNewMotionValues(int16_t x, int16_t y, int16_t z);
|
void OnNewMotionValues(int16_t x, int16_t y, int16_t z);
|
||||||
|
|
||||||
void SubscribeNotification(uint16_t connectionHandle, uint16_t attributeHandle);
|
void SubscribeNotification(uint16_t connectionHandle, uint16_t attributeHandle);
|
||||||
|
|
Loading…
Reference in New Issue