优化
This commit is contained in:
@@ -43,7 +43,7 @@
|
|||||||
android:name=".activity.ShelfActivity"
|
android:name=".activity.ShelfActivity"
|
||||||
android:screenOrientation="portrait"
|
android:screenOrientation="portrait"
|
||||||
tools:ignore="DiscouragedApi,LockedOrientationActivity" />
|
tools:ignore="DiscouragedApi,LockedOrientationActivity" />
|
||||||
<activity android:name="com.shuwei.intelligent.shelves.activity.SettingActivity" />
|
<!-- <activity android:name="com.shuwei.intelligent.shelves.activity.SettingActivity" />-->
|
||||||
<activity android:name="com.shuwei.intelligent.shelves.activity.LogActivity" />
|
<activity android:name="com.shuwei.intelligent.shelves.activity.LogActivity" />
|
||||||
|
|
||||||
<receiver
|
<receiver
|
||||||
|
|||||||
@@ -364,9 +364,9 @@ class ShelfActivity : BaseActivity() {
|
|||||||
val zeroClearingCmd = "${ProtocolConstants.HEADER}0401${hex}${ProtocolConstants.FOOTER}"
|
val zeroClearingCmd = "${ProtocolConstants.HEADER}0401${hex}${ProtocolConstants.FOOTER}"
|
||||||
log("编号${shelfNo}货架执行清零指令:${zeroClearingCmd}")
|
log("编号${shelfNo}货架执行清零指令:${zeroClearingCmd}")
|
||||||
sendCmd(zeroClearingCmd)
|
sendCmd(zeroClearingCmd)
|
||||||
sendCmd(
|
// sendCmd(
|
||||||
if (shelfNo in 1..5) ProtocolConstants.LEFT_SHELF_OPEN_CMD else ProtocolConstants.RIGHT_SHELF_OPEN_CMD
|
// if (shelfNo in 1..5) ProtocolConstants.LEFT_SHELF_OPEN_CMD else ProtocolConstants.RIGHT_SHELF_OPEN_CMD
|
||||||
)
|
// )
|
||||||
//清零
|
//清零
|
||||||
realWeight = 0
|
realWeight = 0
|
||||||
// binding.tvFoodWeight.text = "${realWeight}克"
|
// binding.tvFoodWeight.text = "${realWeight}克"
|
||||||
@@ -374,7 +374,7 @@ class ShelfActivity : BaseActivity() {
|
|||||||
sendCmd(ProtocolConstants.DEVICE_INFO_CMD)
|
sendCmd(ProtocolConstants.DEVICE_INFO_CMD)
|
||||||
startTime = System.currentTimeMillis()
|
startTime = System.currentTimeMillis()
|
||||||
Loading.show(this@ShelfActivity)
|
Loading.show(this@ShelfActivity)
|
||||||
// window.decorView.postDelayed({ Loading.dismiss() }, 5000)
|
window.decorView.postDelayed({ Loading.dismiss() }, 10000)
|
||||||
}
|
}
|
||||||
KeyboardUtil.hideKeyboard(window.decorView)
|
KeyboardUtil.hideKeyboard(window.decorView)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user