修改菜品识别逻辑
This commit is contained in:
@@ -210,9 +210,10 @@ class MainActivity : BaseActivity<ActivityMainBinding>() {
|
||||
Timber.d("registerDataChange weight = $weight")
|
||||
presentation?.updateWeight(weight)
|
||||
|
||||
// if (weight <= 0.005) {//检测到秤上没有东西,重新启动识别菜品
|
||||
// isRecognitionFood = true
|
||||
// }
|
||||
if (weight <= 0.005 && presentation?.mealPickupMode == 1) {//余量取餐,检测到秤上没有东西,重新启动识别菜品
|
||||
isRecognitionFood = true
|
||||
}
|
||||
|
||||
if (weight - lastWeight > 0.05 && isRecognitionFood) { // 大于50g
|
||||
if (presentation?.mealPickupMode == 1) {
|
||||
isRecognitionFood = false
|
||||
|
||||
Reference in New Issue
Block a user