2020-10-20 13:58:08 +07:00
|
|
|
<Page>
|
|
|
|
|
<X> 0 </X>
|
|
|
|
|
<Y> 608 </Y>
|
|
|
|
|
<Cache> "Enable" </Cache>
|
|
|
|
|
<Width> 1080 </Width>
|
|
|
|
|
<Height> 1312 </Height>
|
2021-08-31 14:31:05 +07:00
|
|
|
<Background> "0xEAE6E1" </Background>
|
2020-10-20 13:58:08 +07:00
|
|
|
<Volume> SoundVolume </Volume>
|
|
|
|
|
<EventOpen>
|
|
|
|
|
Var countClick = 0
|
|
|
|
|
Var countClick2 = 0
|
2020-10-29 16:34:12 +07:00
|
|
|
|
|
|
|
|
|
2021-11-24 23:28:56 +07:00
|
|
|
DEBUGVAR MachineStage
|
|
|
|
|
DEBUGVAR stop_now
|
2021-10-25 15:53:30 +07:00
|
|
|
|
|
|
|
|
Var show_error_normal = "Invisible"
|
|
|
|
|
Var show_error_sp1 = "Enable"
|
2022-02-28 22:33:45 +07:00
|
|
|
|
2022-05-02 22:14:11 +07:00
|
|
|
;If EmergencyStop = "true" Then
|
|
|
|
|
; Var stop_now = "true"
|
|
|
|
|
; If show_eng = "true" Then
|
|
|
|
|
; Var DirImage = "ROOT/taobin_project/image/vending_error_en/"
|
|
|
|
|
; Else
|
|
|
|
|
; Var DirImage = "ROOT/taobin_project/image/vending_error"
|
|
|
|
|
; EndIf
|
|
|
|
|
;EndIf
|
2021-10-25 15:53:30 +07:00
|
|
|
|
|
|
|
|
If MachineStage = "mcu-upgrade" Then
|
|
|
|
|
If show_eng = "true" Then
|
|
|
|
|
Var DirImage = "ROOT/taobin_project/image/vending_error_en/"
|
|
|
|
|
Else
|
|
|
|
|
Var DirImage = "ROOT/taobin_project/image/vending_error"
|
|
|
|
|
EndIf
|
2020-10-29 16:34:12 +07:00
|
|
|
EndIf
|
|
|
|
|
|
2021-10-25 15:53:30 +07:00
|
|
|
If NeedUpgrade = "true" Then
|
|
|
|
|
If show_eng = "true" Then
|
|
|
|
|
Var DirImage = "ROOT/taobin_project/image/vending_error_en/"
|
|
|
|
|
|
|
|
|
|
Else
|
|
|
|
|
Var DirImage = "ROOT/taobin_project/image/vending_error"
|
|
|
|
|
EndIf
|
|
|
|
|
EndIf
|
|
|
|
|
|
2022-03-11 09:36:34 +07:00
|
|
|
DEBUGVAR stop_now
|
|
|
|
|
DEBUGVAR MachineStage
|
2021-10-25 15:53:30 +07:00
|
|
|
|
|
|
|
|
If MachineStage = "close-maintenance" Then
|
|
|
|
|
If stop_now = "true" Then
|
|
|
|
|
If show_eng = "true" Then
|
|
|
|
|
Var DirImage = "ROOT/taobin_project/image/vending_error_en/"
|
|
|
|
|
Else
|
|
|
|
|
Var DirImage = "ROOT/taobin_project/image/vending_error"
|
|
|
|
|
EndIf
|
|
|
|
|
Else
|
2022-03-11 09:36:34 +07:00
|
|
|
|
2021-10-25 15:53:30 +07:00
|
|
|
Var show_error_normal = "Enable"
|
|
|
|
|
Var show_error_sp1 = "Invisible"
|
2022-03-11 09:36:34 +07:00
|
|
|
|
2021-10-25 15:53:30 +07:00
|
|
|
If show_eng = "true" Then
|
|
|
|
|
Var DirImage = "ROOT/taobin_project/image/close_en/"
|
|
|
|
|
Else
|
|
|
|
|
Var DirImage = "ROOT/taobin_project/image/close_th"
|
|
|
|
|
EndIf
|
2022-03-11 09:36:34 +07:00
|
|
|
|
2021-10-25 15:53:30 +07:00
|
|
|
EndIf
|
|
|
|
|
EndIf
|
|
|
|
|
|
2022-04-17 21:48:43 +07:00
|
|
|
|
2022-03-11 09:36:34 +07:00
|
|
|
DEBUGVAR DirImage
|
|
|
|
|
|
2021-11-24 23:28:56 +07:00
|
|
|
If MachineStage = "drink-failed" Then
|
|
|
|
|
If stop_now = "true" Then
|
|
|
|
|
If show_eng = "true" Then
|
|
|
|
|
Var DirImage = "ROOT/taobin_project/image/vending_error_en/"
|
|
|
|
|
|
|
|
|
|
Else
|
|
|
|
|
Var DirImage = "ROOT/taobin_project/image/vending_error"
|
|
|
|
|
EndIf
|
|
|
|
|
Else
|
|
|
|
|
Var show_error_normal = "Enable"
|
|
|
|
|
Var show_error_sp1 = "Invisible"
|
|
|
|
|
If show_eng = "true" Then
|
|
|
|
|
Var DirImage = "ROOT/taobin_project/image/close_en/"
|
|
|
|
|
|
|
|
|
|
Else
|
|
|
|
|
Var DirImage = "ROOT/taobin_project/image/close_th"
|
|
|
|
|
EndIf
|
|
|
|
|
EndIf
|
|
|
|
|
EndIf
|
2022-05-01 10:57:47 +07:00
|
|
|
|
|
|
|
|
If NETCORE_LOST_CNT > 0 Then
|
|
|
|
|
If show_eng = "true" Then
|
|
|
|
|
Var DirImage = "ROOT/taobin_project/image/vending_error_en/"
|
|
|
|
|
|
|
|
|
|
Else
|
|
|
|
|
Var DirImage = "ROOT/taobin_project/image/vending_error"
|
|
|
|
|
EndIf
|
|
|
|
|
EndIf
|
|
|
|
|
|
2021-10-25 15:53:30 +07:00
|
|
|
|
2021-01-19 23:43:43 +07:00
|
|
|
StopLongPlay
|
2021-05-04 00:40:17 +07:00
|
|
|
|
2021-05-10 09:55:03 +07:00
|
|
|
If LEDSet = "true" Then
|
|
|
|
|
|
|
|
|
|
Else
|
|
|
|
|
LED LedDoorCup On 255 0 0 255
|
|
|
|
|
LED LedDoorLid Off 255 255 255 255
|
|
|
|
|
EndIf
|
|
|
|
|
|
2022-03-11 09:36:34 +07:00
|
|
|
Var MaintenanceCard = 20
|
2021-08-27 11:46:18 +07:00
|
|
|
Random MaintenanceCard
|
|
|
|
|
Var index = 1 + MaintenanceCard
|
|
|
|
|
|
|
|
|
|
If show_eng = "true" Then
|
|
|
|
|
Var RandomImage = "ROOT/taobin_project/image/close_en/Frame" + index
|
|
|
|
|
Var RandomImage = RandomImage + ".png"
|
|
|
|
|
Else
|
|
|
|
|
Var RandomImage = "ROOT/taobin_project/image/close_en/Frame" + index
|
|
|
|
|
Var RandomImage = RandomImage + ".png"
|
|
|
|
|
EndIf
|
|
|
|
|
|
2022-02-28 22:33:45 +07:00
|
|
|
DEBUGVAR Seeker
|
|
|
|
|
DEBUGVAR DoorCupPosition
|
|
|
|
|
DEBUGVAR DoorLidPosition
|
|
|
|
|
DEBUGVAR EmergencyStop
|
2021-11-24 23:28:56 +07:00
|
|
|
|
2022-03-11 09:36:34 +07:00
|
|
|
Var TimeOut = 0
|
2020-10-20 13:58:08 +07:00
|
|
|
</EventOpen>
|
2021-01-11 14:39:32 +07:00
|
|
|
<Timeout> 5000 </Timeout>
|
2020-10-20 13:58:08 +07:00
|
|
|
<EventTimeout>
|
2022-04-17 21:48:43 +07:00
|
|
|
DEBUGVAR EmergencyStop
|
|
|
|
|
DEBUGVAR NETCORE_LOST_CNT
|
|
|
|
|
DEBUGVAR DoorCupPosition
|
|
|
|
|
DEBUGVAR MachineStage
|
|
|
|
|
|
2022-02-28 22:33:45 +07:00
|
|
|
If EmergencyStop = "true" Then
|
|
|
|
|
If DoorCupPosition = "bottom" Then
|
|
|
|
|
; It normal
|
|
|
|
|
Var EmergencyStop = "false"
|
|
|
|
|
Else
|
|
|
|
|
Var MachineErrorDetailAll = "Emergency stop!"
|
2020-10-20 13:58:08 +07:00
|
|
|
|
2022-02-28 22:33:45 +07:00
|
|
|
EndIf
|
|
|
|
|
Else
|
2020-10-20 13:58:08 +07:00
|
|
|
|
2022-02-28 22:33:45 +07:00
|
|
|
Var MachineErrorDetailAll = MachineErrorDetail + " / "
|
|
|
|
|
Var MachineErrorDetailAll = MachineErrorDetailAll + MachineErrorDetailEng
|
2020-12-05 22:46:39 +07:00
|
|
|
|
2022-02-28 22:33:45 +07:00
|
|
|
DEBUGVAR MachineStage
|
2022-05-05 15:58:19 +07:00
|
|
|
If NETCORE_LOST_CNT > 0 Then
|
|
|
|
|
|
|
|
|
|
Else
|
2022-04-17 21:48:43 +07:00
|
|
|
If MachineStage = "show-menu" Then
|
|
|
|
|
|
|
|
|
|
Var LEDSet = "false"
|
|
|
|
|
Open "ROOT/taobin_project/xml/page_board.xml"
|
2021-11-24 23:28:56 +07:00
|
|
|
|
2022-04-17 21:48:43 +07:00
|
|
|
EndIf
|
|
|
|
|
If MachineStage = "remove-cup" Then
|
|
|
|
|
|
|
|
|
|
Var LEDSet = "false"
|
|
|
|
|
Open "ROOT/taobin_project/xml/page_remove_cup.xml"
|
2021-11-24 23:28:56 +07:00
|
|
|
|
2022-04-17 21:48:43 +07:00
|
|
|
EndIf
|
2022-02-28 22:33:45 +07:00
|
|
|
|
2022-04-17 21:48:43 +07:00
|
|
|
If MachineStage = "drink-failed" Then
|
|
|
|
|
Var FirstOpen = 1
|
2022-02-28 22:33:45 +07:00
|
|
|
Var LEDSet = "true"
|
|
|
|
|
Open "ROOT/taobin_project/xml/page_show_error.xml"
|
|
|
|
|
|
|
|
|
|
EndIf
|
2022-04-17 21:48:43 +07:00
|
|
|
|
|
|
|
|
If FirstOpen = 1 Then
|
|
|
|
|
Var FirstOpen = 0
|
|
|
|
|
If MachineStage = "close-maintenance" Then
|
|
|
|
|
|
|
|
|
|
Var LEDSet = "true"
|
|
|
|
|
Open "ROOT/taobin_project/xml/page_show_error.xml"
|
|
|
|
|
|
|
|
|
|
EndIf
|
|
|
|
|
EndIf
|
2022-02-28 22:33:45 +07:00
|
|
|
EndIf
|
2022-03-11 09:36:34 +07:00
|
|
|
|
|
|
|
|
Var TimeOut = TimeOut + 1
|
|
|
|
|
If TimeOut > 12 Then
|
|
|
|
|
Var TimeOut = 0
|
|
|
|
|
Open "ROOT/taobin_project/xml/page_show_error.xml"
|
|
|
|
|
|
|
|
|
|
EndIf
|
2021-11-24 23:28:56 +07:00
|
|
|
EndIf
|
|
|
|
|
|
2022-02-28 22:33:45 +07:00
|
|
|
|
2021-08-27 13:37:21 +07:00
|
|
|
Refresh
|
|
|
|
|
TimerReset
|
2020-10-20 13:58:08 +07:00
|
|
|
|
2021-05-10 09:55:03 +07:00
|
|
|
Var LEDSet = "true"
|
2021-08-27 13:37:21 +07:00
|
|
|
;Open "ROOT/taobin_project/xml/page_show_error.xml"
|
2020-10-20 13:58:08 +07:00
|
|
|
</EventTimeout>
|
|
|
|
|
|
|
|
|
|
<Image>
|
2021-10-25 15:53:30 +07:00
|
|
|
<State> show_error_normal </State>
|
2020-10-20 13:58:08 +07:00
|
|
|
<X> 127 </X>
|
|
|
|
|
<Y> 688 </Y>
|
2020-10-29 16:34:12 +07:00
|
|
|
<Filename> Var(DirImage + "/img1.png") </Filename>
|
2020-10-20 13:58:08 +07:00
|
|
|
</Image>
|
|
|
|
|
|
2021-08-27 11:46:18 +07:00
|
|
|
<Image>
|
2021-10-25 15:53:30 +07:00
|
|
|
<State> show_error_normal </State>
|
2021-08-27 11:46:18 +07:00
|
|
|
<X> 0 </X>
|
|
|
|
|
<Y> 924 </Y>
|
|
|
|
|
<Filename> RandomImage </Filename>
|
|
|
|
|
</Image>
|
|
|
|
|
|
2021-10-25 15:53:30 +07:00
|
|
|
<Image>
|
|
|
|
|
<State> show_error_sp1 </State>
|
|
|
|
|
<X> 0 </X>
|
|
|
|
|
<Y> 897 </Y>
|
|
|
|
|
<Filename> Var(DirImage + "/img1.png") </Filename>
|
|
|
|
|
</Image>
|
|
|
|
|
|
|
|
|
|
<Image>
|
|
|
|
|
<State> show_error_sp1 </State>
|
|
|
|
|
<X> 0 </X>
|
|
|
|
|
<Y> 694 </Y>
|
|
|
|
|
<Filename> Var(DirImage + "/text1.png") </Filename>
|
|
|
|
|
</Image>
|
|
|
|
|
|
|
|
|
|
<Image>
|
|
|
|
|
<State> show_error_sp1 </State>
|
|
|
|
|
<X> 0 </X>
|
|
|
|
|
<Y> 1685 </Y>
|
|
|
|
|
<Filename> Var(DirImage + "/text2.png") </Filename>
|
|
|
|
|
</Image>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<Button>
|
|
|
|
|
<X> 990 </X>
|
|
|
|
|
<Y> 640 </Y>
|
|
|
|
|
<Filename> show_btn </Filename>
|
|
|
|
|
<FilenamePress> show_btp </FilenamePress>
|
|
|
|
|
<Sound> "/mnt/sdcard/coffeevending/wav/click.wav" </Sound>
|
|
|
|
|
<Volume> SoundVolume </Volume>
|
|
|
|
|
<EventClick>
|
|
|
|
|
; eng
|
|
|
|
|
If show_eng = "true" Then
|
|
|
|
|
Var show_eng = "false"
|
|
|
|
|
Else
|
|
|
|
|
Var show_eng = "true"
|
|
|
|
|
EndIf
|
|
|
|
|
Open "ROOT/taobin_project/xml/page_show_error.xml"
|
|
|
|
|
</EventClick>
|
|
|
|
|
|
2020-10-20 13:58:08 +07:00
|
|
|
<Button>
|
|
|
|
|
<X> 0 </X>
|
|
|
|
|
<Y> 1860 </Y>
|
|
|
|
|
<Width> 200 </Width>
|
|
|
|
|
<Height> 50 </Height>
|
|
|
|
|
<Sound> "/mnt/sdcard/coffeevending/wav/click.wav" </Sound>
|
|
|
|
|
<Volume> SoundVolume </Volume>
|
|
|
|
|
<EventClick>
|
|
|
|
|
Var countClick = countClick + 1
|
|
|
|
|
If countClick = 3 Then
|
|
|
|
|
|
|
|
|
|
EndIf
|
|
|
|
|
|
2022-05-01 10:57:47 +07:00
|
|
|
If countClick = 10 Then
|
2020-10-20 13:58:08 +07:00
|
|
|
Var countClick = 0
|
|
|
|
|
MainMenu
|
|
|
|
|
EndIf
|
|
|
|
|
Refresh
|
|
|
|
|
</EventClick>
|
|
|
|
|
</Button>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<Button>
|
|
|
|
|
<X> 870 </X>
|
|
|
|
|
<Y> 1860 </Y>
|
|
|
|
|
<Width> 200 </Width>
|
|
|
|
|
<Height> 50 </Height>
|
|
|
|
|
<Sound> "/mnt/sdcard/coffeevending/wav/click.wav" </Sound>
|
|
|
|
|
<Volume> SoundVolume </Volume>
|
|
|
|
|
<EventClick>
|
2022-05-01 10:57:47 +07:00
|
|
|
|
2020-10-20 13:58:08 +07:00
|
|
|
</EventClick>
|
|
|
|
|
</Button>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<Text>
|
|
|
|
|
<X> 5 </X>
|
2020-10-29 16:34:12 +07:00
|
|
|
<Y> 1868 </Y>
|
|
|
|
|
<Size> 24 </Size>
|
|
|
|
|
<Align> Center </Align>
|
2020-10-20 13:58:08 +07:00
|
|
|
<Width> 1080 </Width>
|
2020-10-29 16:34:12 +07:00
|
|
|
<Font> RobotoRegular </Font>
|
|
|
|
|
<Color> 0xDE794E </Color>
|
2020-10-20 13:58:08 +07:00
|
|
|
<Value> MachineErrorDetailAll </Value>
|
|
|
|
|
</Text>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</Page>
|