diff options
author | Arthur Ishiguro <arthuri@google.com> | 2023-12-11 23:22:55 +0000 |
---|---|---|
committer | Arthur Ishiguro <arthuri@google.com> | 2023-12-11 23:22:55 +0000 |
commit | 070e169bdbe050a193b1f34feb461360572618a5 (patch) | |
tree | 6e377bca2d160dbe2fe19ab8f62d7e831f725d31 | |
parent | 072d07df7f15c07f33f6f5565b0de9e1db0d677b (diff) | |
download | libhardware-070e169bdbe050a193b1f34feb461360572618a5.tar.gz |
Only send head tracker v2.0 transport selection on enable
Bug: 298450041
Test: Compile
Change-Id: I0da896913f09a8215189974cf294d6b2a26d12f8
-rw-r--r-- | modules/sensors/dynamic_sensor/HidRawSensor.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/sensors/dynamic_sensor/HidRawSensor.cpp b/modules/sensors/dynamic_sensor/HidRawSensor.cpp index dcf4b470..939b58df 100644 --- a/modules/sensors/dynamic_sensor/HidRawSensor.cpp +++ b/modules/sensors/dynamic_sensor/HidRawSensor.cpp @@ -998,7 +998,7 @@ int HidRawSensor::enable(bool enable) { std::vector<uint8_t> buffer; // TODO(b/298450041): Refactor the operations below in a separate function. bool setLeAudioTransportOk = true; - if (mLeTransportId >= 0) { + if (mLeTransportId >= 0 && enable) { setLeAudioTransportOk = false; uint8_t id = static_cast<uint8_t>(mLeTransportId); if (device->getFeature(id, &buffer) |