This commit is contained in:
wanlop run 2024-07-09 16:02:08 +07:00
parent 79fc27dc9b
commit 19ffebde48
6 changed files with 125 additions and 117 deletions

View file

@ -12806,6 +12806,91 @@ LIMENADE SODA" </Value>
<Button>
<X> 42 </X>
<Y> 518 </Y>
<State> BigButtonEnable </State>
<Filename>
eval(
If show_eng = "true" Then
Var return = "ROOT/taobin_project/image/event/cocoa77/cocoa77.png"
Else
Var return = "ROOT/taobin_project/image/event/cocoa77/cocoa77.png"
EndIf
)
</Filename>
<FilenamePress>
eval(
If show_eng = "true" Then
Var return = "ROOT/taobin_project/image/event/cocoa77/cocoa77.png"
Else
Var return = "ROOT/taobin_project/image/event/cocoa77/cocoa77.png"
EndIf
)
</FilenamePress>
<FilenameDisable>
eval(
If show_eng = "true" Then
Var return = "ROOT/taobin_project/image/event/cocoa77/cocoa77.png"
Else
Var return = "ROOT/taobin_project/image/event/cocoa77/cocoa77.png"
EndIf
)
</FilenameDisable>
<EventOnClick>
Open "ROOT/taobin_project/xml/page_catalog_group_pro_cocoa_77_ignore.xml"
</EventOnClick>
<Video>
<X> 42 </X>
<Y> 518 </Y>
<Width> 484 </Width>
<Height> 616 </Height>
<Loop> "true" </Loop>
<State>
eval(
If show_eng = "true" Then
Var return = "Invisible"
Else
Var return = "Enable"
EndIf
)
</State>
<Filename> "ROOT/taobin_project/image/event/cocoa77/cocoa77.mp4" </Filename>
</Video>
<Video>
<X> 42 </X>
<Y> 518 </Y>
<Width> 484 </Width>
<Height> 616 </Height>
<State>
eval(
If show_eng = "true" Then
Var return = "Enable"
Else
Var return = "Invisible"
EndIf
)
</State>
<Loop> "true" </Loop>
<Filename> "ROOT/taobin_project/image/event/cocoa77/cocoa77.mp4" </Filename>
</Video>
</Button>
<EventUnitTest1>
Var BigButtonEnable = "Enable"
Refresh
</EventUnitTest1>
<EventUnitTest2>
Var BigButtonEnable = "Invisible"
Refresh
</EventUnitTest2>
<Button>
<X> 780 </X>

View file

@ -1108,6 +1108,8 @@
Var ShowButtonClick2 = "Invisible"
EndIf
Machine OrderCheck
DEBUGVAR CLOSE_ORDER_NOW
; move to TRY actoin.
@ -1220,7 +1222,12 @@
<EventUnitTest4>
PRICE "Load" "-"
PRICE "Check" XMLProfile
PRICE "CheckAndApply" XMLProfile
DEBUGVAR ProfileIndex[0]
DEBUGVAR ProfileIndex[1]
DEBUGVAR ProfileIndex[2]
</EventUnitTest4>
<EventDrink>

View file

@ -20,6 +20,7 @@
Var NightTime = 0
Machine WakeUp
Machine OrderCheck
DEBUGVAR ToppingNewShow

View file

@ -44,10 +44,7 @@
LED LedDoorDoor 5 255 255 255 255
Var TimeoutInstance0 = 0
Var CheckCupStateDoorCupClose = "-"
Var CheckCupStateDoorCupCloseCnt = 0
Var CoundUpDelayCertainStage = 0
;include=ROOT/taobin_project/inc/remove_cup_event_open.inc
</EventOpen>
<Timeout> 1000 </Timeout>
<EventTimeout>
@ -63,102 +60,7 @@
;DEBUGVAR CupArmMove
;DEBUGVAR buttonRemoveCup
; Add haveCup false for block display abnormal. Alternate between page_board.xml and this file.
If HaveCup = "false" Then
If MachineStage = "show-menu" Then
Open "ROOT/taobin_project/xml/page_board.xml"
EndIf
EndIf
If MachineStage = "close-maintenance" Then
Open "ROOT/taobin_project/xml/page_show_error.xml"
EndIf
Var Timeout = Timeout + 1
If Timeout > 15 Then
Var Timeout = 0
EndIf
Var TimeoutInstance0 = TimeoutInstance0 + 1
If TimeoutInstance0 > 600 Then
Var TimeoutInstance0 = 0
SAVELOG "Check Cup all"
Machine CheckCupAll
EndIf
; Logic have differrent drinkfail3.xml
; protect lock
;
If CheckCupStateDoorCupCloseCnt > 0 Then
Var CheckCupStateDoorCupCloseCnt = CheckCupStateDoorCupCloseCnt - 1
DEBUGVAR CheckCupStateDoorCupCloseCnt
If CheckCupStateDoorCupCloseCnt = 0 Then
Var CheckCupStateDoorCupClose = ""
EndIf
EndIf
If HaveCup = "true" Then
If CheckCupStateDoorCupClose = "" Then
Var buttonRemoveCup = "Enable"
EndIf
Else
If buttonRemoveCup = "Enable" Then
Var buttonRemoveCup = "Invisible"
EndIf
EndIf
If DoorCupPosition = "bottom" Then
Else
Var buttonRemoveCup = "Invisible"
Var CoundUpDelayCertainStage = 0
EndIf
If CupArmMove = "true" Then
Var buttonRemoveCup = "Invisible"
If show_eng = "true" Then
Var MachineErrorDetailAll = "Please wait."
Else
Var MachineErrorDetailAll = "กรุณารอสักครู่"
EndIf
Else
If CupArmMove = "false" Then
If HaveCup = "true" Then
If DoorCupPosition = "bottom" Then
If buttonRemoveCup = "Invisible" Then
Var CoundUpDelayCertainStage = CoundUpDelayCertainStage + 1
If CoundUpDelayCertainStage > 2 Then
Var buttonRemoveCup = "Enable"
EndIf
EndIf
EndIf
EndIf
EndIf
EndIf
If show_eng = "true" Then
Else
If Timeout = 0 Then
If buttonRemoveCup = "Enable" Then
If CupChecking = "false" Then
If DoorCupPosition = "bottom" Then
Play "/mnt/sdcard/coffeevending/taobin_project/sound_thai/remove_cup.mp3"
EndIf
EndIf
EndIf
EndIf
EndIf
;include=ROOT/taobin_project/inc/remove_cup_step.inc
Refresh
TimerReset
@ -166,6 +68,20 @@
</EventTimeout>
<EventMachineCupReady>
SAVELOG "EventMachineCupReady"
Var buttonRemoveCup = "Invisible"
Var HaveCup = "false"
Refresh
</EventMachineCupReady>
<EventMachineCupNotReady>
SAVELOG "EventMachineCupNotReady"
Var CoundUpDelayCertainStage = 5
</EventMachineCupNotReady>
<EventDrink>
SAVELOG "EventDrink"
DEBUGVAR HaveCup
@ -174,13 +90,9 @@
DEBUGVAR CupChecking
DEBUGVAR CupArmMove
If HaveCup = "true" Then
Var buttonRemoveCup = "Enable"
Else
Var buttonRemoveCup = "Invisible"
EndIf
</EventDrink>
<Image>
<X> 0 </X>
<Y> 852 </Y>
@ -198,15 +110,8 @@
<EventClick>
Machine RemoveCup
Machine DoorLidOpen
Var buttonRemoveCup = "Invisible"
; protect value update too slow.
Var DoorCupPosition = "-"
;include=ROOT/taobin_project/inc/remove_cup_button.inc
Var CheckCupStateDoorCupClose = "reset"
Var CheckCupStateDoorCupCloseCnt = 30
Refresh
</EventClick>
</Button>