|
@@ -32,10 +32,10 @@ class DockBean(
|
|
|
when (it) {
|
|
when (it) {
|
|
|
DOCK_TYPE_KEY -> {
|
|
DOCK_TYPE_KEY -> {
|
|
|
// TODO 未验证
|
|
// TODO 未验证
|
|
|
- val leftHasKey = (byteArray[4].toInt() shr 0) and 0x1 == 1
|
|
|
|
|
- val isLeftCharging = (byteArray[4].toInt() shr 1) and 0x1 == 1
|
|
|
|
|
- val rightHasKey = (byteArray[3].toInt() shr 0) and 0x1 == 1
|
|
|
|
|
- val isRightCharging = (byteArray[3].toInt() shr 1) and 0x1 == 1
|
|
|
|
|
|
|
+ val rightHasKey = (byteArray[4].toInt() shr 0) and 0x1 == 1
|
|
|
|
|
+ val isRightCharging = (byteArray[4].toInt() shr 1) and 0x1 == 1
|
|
|
|
|
+ val leftHasKey = (byteArray[3].toInt() shr 0) and 0x1 == 1
|
|
|
|
|
+ val isLeftCharging = (byteArray[3].toInt() shr 1) and 0x1 == 1
|
|
|
LogUtil.i("钥匙刷新状态 : $leftHasKey - $isLeftCharging - $rightHasKey - $isRightCharging")
|
|
LogUtil.i("钥匙刷新状态 : $leftHasKey - $isLeftCharging - $rightHasKey - $isRightCharging")
|
|
|
if (getKeyList().isEmpty()) {
|
|
if (getKeyList().isEmpty()) {
|
|
|
deviceList.add(KeyBean(0, leftHasKey, true, isLeftCharging, null, null))
|
|
deviceList.add(KeyBean(0, leftHasKey, true, isLeftCharging, null, null))
|