K01:
authordxy15521469561 <1731678236@qq.com>
Tue, 9 Jul 2024 01:29:05 +0000 (09:29 +0800)
committerdxy15521469561 <1731678236@qq.com>
Tue, 9 Jul 2024 01:29:05 +0000 (09:29 +0800)
bug修复
W9:
部分UI调整

2.sdk-ZY/project/K01/sdk/services/microPython/ports/quectel/core/mgr.py
2.sdk-ZY/project/K01/sdk/services/microPython/ports/quectel/core/ui.py
2.sdk-ZY/project/K01/sdk/system/platform/ASR_1606/boards/EG810MCN_GA_VOLTE/libraries/libHeliosAPI.lib
2.sdk-ZY/project/K01/sdk/system/platform/ASR_1606/boards/EG810MCN_GA_VOLTE/libraries/ql_common_api.lib
2.sdk-ZY/project/W9/sdk/services/microPython/ports/quectel/core/mgr.py
2.sdk-ZY/project/W9/sdk/services/microPython/ports/quectel/core/ui.py
2.sdk-ZY/project/W9/sdk/services/microPython/ports/quectel/core/ui_setting.py
2.sdk-ZY/project/W9/usr/static/SOS_PLAY.mp3 [deleted file]
2.sdk-ZY/project/W9/usr/static/cancel_icon.png [deleted file]
2.sdk-ZY/project/W9/usr/static/low_power.png

index e023d3a..1aa8d5d 100644 (file)
@@ -468,8 +468,8 @@ def WL_timer_cb(*args):
         EventMesh.publish("answer_auto_event")
 
 def voice_callback(args):
-   print('voicecall iinfo:{}'.format(args))
-   if args[0] == 10:
+    print('voicecall iinfo:{}'.format(args))
+    if args[0] == 10:
         get_UI_high_priority = EventMesh.publish("get_UI_high_priority")#如果在拨出去或者通话中屏蔽来电
         if get_UI_high_priority == 1:
             EventMesh.publish("set_interrup_incall",1)
@@ -506,12 +506,14 @@ def voice_callback(args):
                     EventMesh.publish("set_call_state",0)
                     EventMesh.publish("set_interrup_incall",0)
                     EventMesh.publish("set_UI_high_priority",0)
+                    EventMesh.publish("return_prev_screen")
                     voiceCall.callEnd()
+                    
                     return 
         EventMesh.publish("set_call_state",2)#设置
         EventMesh.publish("load_screen", {"screen": "incoming_call","meta":str(tmp)})
 
-   elif args[0] == 11:
+    elif args[0] == 11:
         EventMesh.publish("set_UI_high_priority",0)
         sos_flag = EventMesh.publish("get_sos_flag")
         if sos_flag == 1:
@@ -531,7 +533,7 @@ def voice_callback(args):
         EventMesh.publish("set_call_state",1)#设置
         EventMesh.publish("load_screen", {"screen": "on_call","meta":str(tmp)})
 
-   elif args[0] == 12:
+    elif args[0] == 12:
         set_interrup_call = EventMesh.publish("get_interrup_incall")#打断这次不需要来电的ui事件 以免通话中退出当前界面进不去了
         if set_interrup_call == 1:
             EventMesh.publish("set_interrup_incall",0)
@@ -550,9 +552,9 @@ def voice_callback(args):
         print('voicecall disconnect end')
         
 
-   elif args[0] == 13:
+    elif args[0] == 13:
         print('voicecall is waiting, PhoneNO.: ', args[6])
-   elif args[0] == 14:
+    elif args[0] == 14:
         print('voicecall dialing, PhoneNO.: ', args[6],EventMesh.publish("get_phone_state"))
         if EventMesh.publish("get_phone_state") == 0:
             EventMesh.publish("set_call_state",0)
@@ -561,14 +563,14 @@ def voice_callback(args):
             voiceCall.callEnd()
             return
         EventMesh.publish("set_call_state",4)##设置通话状态
-        
+        EventMesh.publish("set_interrup_incall",0)
         EventMesh.publish("set_UI_high_priority",0)
         EventMesh.publish("load_screen", {"screen": "dialing_noplay_popup"})
         
-   elif args[0] == 15:
+    elif args[0] == 15:
         print('voicecall alerting, PhoneNO.: ', args[6])
         
-   elif args[0] == 16:
+    elif args[0] == 16:
         print('voicecall holding, PhoneNO.: ', args[6])
 
 class DeviceInfoManager(Abstract):
index 90f3689..24bf8a4 100644 (file)
@@ -1325,8 +1325,9 @@ class DialingScreen(Screen):
         EventMesh.publish("set_interrup_incall",0)
         EventMesh.publish("set_UI_high_priority",0)
         EventMesh.publish("set_call_state",0)#设置通话状态为0
-        voiceCall.callEnd()
         EventMesh.publish("return_prev_screen")
+        voiceCall.callEnd()
+        
 
     def Close(self):
         self.timer.stop()
@@ -1876,8 +1877,9 @@ class DialingNoPlayPopupScreen(Screen):#正在拨号中...未打出
             EventMesh.publish("set_interrup_incall",0)
             EventMesh.publish("set_UI_high_priority",0)
             EventMesh.publish("set_call_state",0)#设置通话状态为0
-            voiceCall.callEnd()
             EventMesh.publish("return_prev_screen")
+            voiceCall.callEnd()
+            
 
     def hangup(self,e):
         self.phone_page_state = 0
@@ -1894,8 +1896,9 @@ class DialingNoPlayPopupScreen(Screen):#正在拨号中...未打出
         EventMesh.publish("set_interrup_incall",0)
         EventMesh.publish("set_UI_high_priority",0)
         EventMesh.publish("set_call_state",0)#设置通话状态为0
-        voiceCall.callEnd()
         EventMesh.publish("return_prev_screen")
+        voiceCall.callEnd()
+        
         # EventMesh.publish("load_screen", {"screen": "main_menu"})  
 
     def Close(self):
@@ -3546,10 +3549,12 @@ class IncomingCallScreen(Screen):
         self.call_timer1.stop()
         self.call_timer.stop()
         EventMesh.publish("set_call_state",0)#设置通话状态为0
-        voiceCall.callEnd()
         EventMesh.publish("set_interrup_incall",0)
         EventMesh.publish("set_UI_high_priority",0)
         EventMesh.publish("return_prev_screen")
+        voiceCall.callEnd()
+        
+        
 
 
     def btn1_release(self):
@@ -4199,10 +4204,11 @@ class OnCallScreen(Screen):
         EventMesh.publish("set_UI_high_priority", 0)
         self.timer.stop()
         EventMesh.publish("set_call_state",0)#设置通话状态为0
-        voiceCall.callEnd()
         EventMesh.publish("set_interrup_incall",0)
         EventMesh.publish("set_UI_high_priority",0)
         EventMesh.publish("return_prev_screen")
+        voiceCall.callEnd()
+        
                 # EventMesh.publish("load_screen", {"screen": "main_menu"})  
         
     def Close(self):
index 7852260..8f0ae18 100644 (file)
Binary files a/2.sdk-ZY/project/K01/sdk/system/platform/ASR_1606/boards/EG810MCN_GA_VOLTE/libraries/libHeliosAPI.lib and b/2.sdk-ZY/project/K01/sdk/system/platform/ASR_1606/boards/EG810MCN_GA_VOLTE/libraries/libHeliosAPI.lib differ
index 1dc8ac0..2c9d26b 100644 (file)
Binary files a/2.sdk-ZY/project/K01/sdk/system/platform/ASR_1606/boards/EG810MCN_GA_VOLTE/libraries/ql_common_api.lib and b/2.sdk-ZY/project/K01/sdk/system/platform/ASR_1606/boards/EG810MCN_GA_VOLTE/libraries/ql_common_api.lib differ
index 139db0b..df80b1e 100644 (file)
@@ -614,7 +614,12 @@ def voice_callback(args):
                         WL_timer.start(30000, 0, WL_timer_cb)
                 else:
                     print("voice_callback:不在白名单中,挂断")
+                    EventMesh.publish("set_call_state",0)
+                    EventMesh.publish("set_interrup_incall",0)
+                    EventMesh.publish("set_UI_high_priority",0)
+                    EventMesh.publish("return_prev_screen")
                     voiceCall.callEnd()
+                    
                     return 
         EventMesh.publish("set_call_state",2)#设置
         EventMesh.publish("load_screen", {"screen": "incoming_call","meta":str(tmp)})
@@ -649,10 +654,8 @@ def voice_callback(args):
         EventMesh.publish("set_UI_high_priority",0)
         
 
-        screen_NAME = EventMesh.publish("get_screen_NAME")
-        if screen_NAME != None:
-            if screen_NAME != "dialing_noplay_popup":
-                EventMesh.publish("return_prev_screen")  
+        if EventMesh.publish("get_call_state") != 0:
+            EventMesh.publish("return_prev_screen")  
         
         EventMesh.publish("set_sos_info_call")  
         print('voicecall disconnect end')
@@ -662,10 +665,16 @@ def voice_callback(args):
    elif args[0] == 13:
         print('voicecall is waiting, PhoneNO.: ', args[6])
    elif args[0] == 14:
+        if EventMesh.publish("get_phone_state") == 0:
+            EventMesh.publish("set_call_state",0)
+            EventMesh.publish("set_interrup_incall",0)
+            EventMesh.publish("set_UI_high_priority",0)
+            voiceCall.callEnd()
+            return
         EventMesh.publish("set_call_state",4)##设置通话状态
-        print('voicecall dialing, PhoneNO.: ', args[6])
+        EventMesh.publish("set_interrup_incall",0)
         EventMesh.publish("set_UI_high_priority",0)
-        EventMesh.publish("load_screen", {"screen": "dialing"})
+        EventMesh.publish("load_screen", {"screen": "dialing_noplay_popup"})
         
    elif args[0] == 15:
         print('voicecall alerting, PhoneNO.: ', args[6])
@@ -699,6 +708,8 @@ class DeviceInfoManager(Abstract):
 
         self.step = [0,0,0,0]
         self.timer_push=0
+
+        self.alarm_rtc = 0
         self.timer_push_tmp=60
         self.PING = "0" #绑定状态
         self.connect = 0 #服务器连接状态
@@ -952,7 +963,11 @@ class DeviceInfoManager(Abstract):
             date_tmp = utime.localtime()
             time_tmp = utime.mktime(date_tmp)
             # print("date_tmp......01....{} time_tmp:{}\r\n".format(date_tmp,time_tmp))
-            
+            if self.alarm_rtc <= (5*60)/10:
+                self.alarm_rtc+=1
+                if self.alarm_rtc == 29:
+                    EventMesh.publish("set_rtc_alarm")
+                    
             """sos下发通知 没有收到1分钟请求一次"""
             sos_state = EventMesh.publish("get_sos_status")
             
index 4d0ed92..4d2cef9 100644 (file)
@@ -23,6 +23,7 @@ from queue import Queue
 from machine import RTC
 import usys
 from lcd import LCD_SIZE_W,LCD_SIZE_H
+from ui_setting import style_screen_btn_1_main_main_default
 
 
 def audio_cb(event):
@@ -1387,13 +1388,14 @@ class DialingScreen(Screen):
     def hangup(self,e):
         code = e.get_code()
         if  code == lv.EVENT.SHORT_CLICKED:
-            EventMesh.publish("set_UI_high_priority", 0)
             EventMesh.publish("close_sos_timer")
             EventMesh.publish("set_hangup_mode", 1)
-            voiceCall.callEnd()
+            EventMesh.publish("set_call_state",0)#设置通话状态为0
             EventMesh.publish("set_interrup_incall",0)
             EventMesh.publish("set_UI_high_priority",0)
             EventMesh.publish("return_prev_screen")
+            voiceCall.callEnd()
+            
 
     def Close(self):
         self.timer.stop()
@@ -1603,29 +1605,82 @@ class NoSimPowerScreen(Screen):#
             no_sim_power_screen_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
 
 
-            no_sim_power_screen_comfirm = lv.img(no_sim_power_screen)
-            no_sim_power_screen_comfirm.set_size(176, 46)
-            no_sim_power_screen_comfirm.set_pos(32, 175)
-            no_sim_power_screen_comfirm.set_src("U:/static/off_icon.png")
-            no_sim_power_screen_comfirm.add_flag(lv.obj.FLAG.CLICKABLE)
-            no_sim_power_screen_comfirm.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
-
-            poweroff_confirm_label = lv.label(no_sim_power_screen_comfirm)
-            poweroff_confirm_label.set_text("确定")
-            poweroff_confirm_label.align(lv.ALIGN.CENTER, 0, 5)
-            poweroff_confirm_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
-
-            no_sim_power_screen_cancel = lv.img(no_sim_power_screen)
-            no_sim_power_screen_cancel.set_size(176, 46)
-            no_sim_power_screen_cancel.set_pos(32, 235)
-            no_sim_power_screen_cancel.set_src("U:/static/cancel_icon.png")
-            no_sim_power_screen_cancel.add_flag(lv.obj.FLAG.CLICKABLE)
-            no_sim_power_screen_cancel.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
-            poweroff_return_label = lv.label(no_sim_power_screen_cancel)
-            poweroff_return_label.set_text("取消")
-            poweroff_return_label.align(lv.ALIGN.CENTER, 0, 5)
-            poweroff_return_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
-            no_sim_power_screen_cancel.set_ext_click_area(20)
+            # no_sim_power_screen_comfirm = lv.img(no_sim_power_screen)
+            # no_sim_power_screen_comfirm.set_size(176, 46)
+            # no_sim_power_screen_comfirm.set_pos(32, 175)
+            # no_sim_power_screen_comfirm.set_src("U:/static/off_icon.png")
+            # no_sim_power_screen_comfirm.add_flag(lv.obj.FLAG.CLICKABLE)
+            # no_sim_power_screen_comfirm.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+            # poweroff_confirm_label = lv.label(no_sim_power_screen_comfirm)
+            # poweroff_confirm_label.set_text("确定")
+            # poweroff_confirm_label.align(lv.ALIGN.CENTER, 0, 5)
+            # poweroff_confirm_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+            no_sim_power_screen_comfirm = lv.btn(no_sim_power_screen)
+            no_sim_power_screen_comfirm.set_pos(int(32),int(46))
+            no_sim_power_screen_comfirm.set_size(176,46)
+            no_sim_power_screen_comfirm.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+            screen_btn_1_label = lv.label(no_sim_power_screen_comfirm)
+            screen_btn_1_label.set_text("确定")
+            no_sim_power_screen_comfirm.set_style_pad_all(0, lv.STATE.DEFAULT)
+            screen_btn_1_label.align(lv.ALIGN.CENTER,0,0)
+            # create style style_screen_btn_1_main_main_default
+            style_screen_btn_1_main_main_default = lv.style_t()
+            style_screen_btn_1_main_main_default.init()
+            style_screen_btn_1_main_main_default.set_radius(20)
+            style_screen_btn_1_main_main_default.set_bg_color(lv.color_make(249,47,109))
+            style_screen_btn_1_main_main_default.set_bg_grad_color(lv.color_make(249,47,109))
+            style_screen_btn_1_main_main_default.set_bg_grad_dir(lv.GRAD_DIR.NONE)
+            style_screen_btn_1_main_main_default.set_bg_opa(255)
+            style_screen_btn_1_main_main_default.set_border_color(lv.color_make(249,47,109))
+            style_screen_btn_1_main_main_default.set_border_width(0)
+            style_screen_btn_1_main_main_default.set_border_opa(255)
+            style_screen_btn_1_main_main_default.set_text_color(lv.color_make(0xff,0xff,0xff))
+            style_screen_btn_1_main_main_default.set_text_font(lv.K01_font_16_ALL)
+            style_screen_btn_1_main_main_default.set_text_align(lv.TEXT_ALIGN.CENTER)
+
+            # add style for screen_btn_1
+            no_sim_power_screen_comfirm.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
+
+
+            # no_sim_power_screen_cancel = lv.img(no_sim_power_screen)
+            # no_sim_power_screen_cancel.set_size(176, 46)
+            # no_sim_power_screen_cancel.set_pos(32, 235)
+            # no_sim_power_screen_cancel.set_src("U:/static/cancel_icon.png")
+            # no_sim_power_screen_cancel.add_flag(lv.obj.FLAG.CLICKABLE)
+            # no_sim_power_screen_cancel.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+            # poweroff_return_label = lv.label(no_sim_power_screen_cancel)
+            # poweroff_return_label.set_text("取消")
+            # poweroff_return_label.align(lv.ALIGN.CENTER, 0, 5)
+            # poweroff_return_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
+            # no_sim_power_screen_cancel.set_ext_click_area(20)
+
+            no_sim_power_screen_cancel = lv.btn(no_sim_power_screen)
+            no_sim_power_screen_cancel.set_pos(int(32),int(230))
+            no_sim_power_screen_cancel.set_size(176,46)
+            no_sim_power_screen_cancel.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+            screen_btn_1_label = lv.label(no_sim_power_screen_cancel)
+            screen_btn_1_label.set_text("取消")
+            no_sim_power_screen_cancel.set_style_pad_all(0, lv.STATE.DEFAULT)
+            screen_btn_1_label.align(lv.ALIGN.CENTER,0,0)
+            # create style style_screen_btn_1_main_main_default
+            style_screen_btn_1_main_main_default = lv.style_t()
+            style_screen_btn_1_main_main_default.init()
+            style_screen_btn_1_main_main_default.set_radius(20)
+            style_screen_btn_1_main_main_default.set_bg_color(lv.color_make(7,222,169))
+            style_screen_btn_1_main_main_default.set_bg_grad_color(lv.color_make(7,222,169))
+            style_screen_btn_1_main_main_default.set_bg_grad_dir(lv.GRAD_DIR.NONE)
+            style_screen_btn_1_main_main_default.set_bg_opa(255)
+            style_screen_btn_1_main_main_default.set_border_color(lv.color_make(7,222,169))
+            style_screen_btn_1_main_main_default.set_border_width(0)
+            style_screen_btn_1_main_main_default.set_border_opa(255)
+            style_screen_btn_1_main_main_default.set_text_color(lv.color_make(0xff,0xff,0xff))
+            style_screen_btn_1_main_main_default.set_text_font(lv.K01_font_16_ALL)
+            style_screen_btn_1_main_main_default.set_text_align(lv.TEXT_ALIGN.CENTER)
+
+            # add style for screen_btn_1
+            no_sim_power_screen_cancel.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
 
             self.meta = no_sim_power_screen
             no_sim_power_screen.add_event_cb(lambda e:EventMesh.callback_wrapper(self.button_cb(e,1)), lv.EVENT.GESTURE, None)
@@ -1717,29 +1772,81 @@ class NoSimAutoScreen(Screen):#无sim卡是否关机
             no_sim_auto_screen_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
 
 
-            no_sim_auto_screen_comfirm = lv.img(no_sim_auto_screen)
-            no_sim_auto_screen_comfirm.set_size(176, 46)
-            no_sim_auto_screen_comfirm.set_pos(32, 185)
-            no_sim_auto_screen_comfirm.set_src("U:/static/off_icon.png")
-            no_sim_auto_screen_comfirm.add_flag(lv.obj.FLAG.CLICKABLE)
-            no_sim_auto_screen_comfirm.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
-
-            no_sim_confirm_label = lv.label(no_sim_auto_screen_comfirm)
-            no_sim_confirm_label.set_text("确定")
-            no_sim_confirm_label.align(lv.ALIGN.CENTER, 0, 5)
-            no_sim_confirm_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
-
-            no_sim_auto_screen_cancel = lv.img(no_sim_auto_screen)
-            no_sim_auto_screen_cancel.set_size(176, 46)
-            no_sim_auto_screen_cancel.set_pos(32, 238)
-            no_sim_auto_screen_cancel.set_src("U:/static/cancel_icon.png")
-            no_sim_auto_screen_cancel.add_flag(lv.obj.FLAG.CLICKABLE)
-            no_sim_auto_screen_cancel.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
-            no_sim_cancel_label = lv.label(no_sim_auto_screen_cancel)
-            no_sim_cancel_label.set_text("取消")
-            no_sim_cancel_label.align(lv.ALIGN.CENTER, 0, 5)
-            no_sim_cancel_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
-            no_sim_auto_screen_cancel.set_ext_click_area(20)
+            # no_sim_auto_screen_comfirm = lv.img(no_sim_auto_screen)
+            # no_sim_auto_screen_comfirm.set_size(176, 46)
+            # no_sim_auto_screen_comfirm.set_pos(32, 185)
+            # no_sim_auto_screen_comfirm.set_src("U:/static/off_icon.png")
+            # no_sim_auto_screen_comfirm.add_flag(lv.obj.FLAG.CLICKABLE)
+            # no_sim_auto_screen_comfirm.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+            # no_sim_confirm_label = lv.label(no_sim_auto_screen_comfirm)
+            # no_sim_confirm_label.set_text("确定")
+            # no_sim_confirm_label.align(lv.ALIGN.CENTER, 0, 5)
+            # no_sim_confirm_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+            no_sim_auto_screen_comfirm = lv.btn(no_sim_auto_screen)
+            no_sim_auto_screen_comfirm.set_pos(int(32),int(46))
+            no_sim_auto_screen_comfirm.set_size(176,46)
+            no_sim_auto_screen_comfirm.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+            screen_btn_1_label = lv.label(no_sim_auto_screen_comfirm)
+            screen_btn_1_label.set_text("确定")
+            no_sim_auto_screen_comfirm.set_style_pad_all(0, lv.STATE.DEFAULT)
+            screen_btn_1_label.align(lv.ALIGN.CENTER,0,0)
+            # create style style_screen_btn_1_main_main_default
+            style_screen_btn_1_main_main_default = lv.style_t()
+            style_screen_btn_1_main_main_default.init()
+            style_screen_btn_1_main_main_default.set_radius(20)
+            style_screen_btn_1_main_main_default.set_bg_color(lv.color_make(249,47,109))
+            style_screen_btn_1_main_main_default.set_bg_grad_color(lv.color_make(249,47,109))
+            style_screen_btn_1_main_main_default.set_bg_grad_dir(lv.GRAD_DIR.NONE)
+            style_screen_btn_1_main_main_default.set_bg_opa(255)
+            style_screen_btn_1_main_main_default.set_border_color(lv.color_make(249,47,109))
+            style_screen_btn_1_main_main_default.set_border_width(0)
+            style_screen_btn_1_main_main_default.set_border_opa(255)
+            style_screen_btn_1_main_main_default.set_text_color(lv.color_make(0xff,0xff,0xff))
+            style_screen_btn_1_main_main_default.set_text_font(lv.K01_font_16_ALL)
+            style_screen_btn_1_main_main_default.set_text_align(lv.TEXT_ALIGN.CENTER)
+
+            # add style for screen_btn_1
+            no_sim_auto_screen_comfirm.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
+
+            # no_sim_auto_screen_cancel = lv.img(no_sim_auto_screen)
+            # no_sim_auto_screen_cancel.set_size(176, 46)
+            # no_sim_auto_screen_cancel.set_pos(32, 238)
+            # no_sim_auto_screen_cancel.set_src("U:/static/cancel_icon.png")
+            # no_sim_auto_screen_cancel.add_flag(lv.obj.FLAG.CLICKABLE)
+            # no_sim_auto_screen_cancel.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+            # no_sim_cancel_label = lv.label(no_sim_auto_screen_cancel)
+            # no_sim_cancel_label.set_text("取消")
+            # no_sim_cancel_label.align(lv.ALIGN.CENTER, 0, 5)
+            # no_sim_cancel_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
+            # no_sim_auto_screen_cancel.set_ext_click_area(20)
+
+            no_sim_auto_screen_cancel = lv.btn(no_sim_auto_screen)
+            no_sim_auto_screen_cancel.set_pos(int(32),int(230))
+            no_sim_auto_screen_cancel.set_size(176,46)
+            no_sim_auto_screen_cancel.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+            screen_btn_1_label = lv.label(no_sim_auto_screen_cancel)
+            screen_btn_1_label.set_text("取消")
+            no_sim_auto_screen_cancel.set_style_pad_all(0, lv.STATE.DEFAULT)
+            screen_btn_1_label.align(lv.ALIGN.CENTER,0,0)
+            # create style style_screen_btn_1_main_main_default
+            style_screen_btn_1_main_main_default = lv.style_t()
+            style_screen_btn_1_main_main_default.init()
+            style_screen_btn_1_main_main_default.set_radius(20)
+            style_screen_btn_1_main_main_default.set_bg_color(lv.color_make(7,222,169))
+            style_screen_btn_1_main_main_default.set_bg_grad_color(lv.color_make(7,222,169))
+            style_screen_btn_1_main_main_default.set_bg_grad_dir(lv.GRAD_DIR.NONE)
+            style_screen_btn_1_main_main_default.set_bg_opa(255)
+            style_screen_btn_1_main_main_default.set_border_color(lv.color_make(7,222,169))
+            style_screen_btn_1_main_main_default.set_border_width(0)
+            style_screen_btn_1_main_main_default.set_border_opa(255)
+            style_screen_btn_1_main_main_default.set_text_color(lv.color_make(0xff,0xff,0xff))
+            style_screen_btn_1_main_main_default.set_text_font(lv.K01_font_16_ALL)
+            style_screen_btn_1_main_main_default.set_text_align(lv.TEXT_ALIGN.CENTER)
+
+            # add style for screen_btn_1
+            no_sim_auto_screen_cancel.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
 
             self.meta = no_sim_auto_screen
 
@@ -1837,8 +1944,11 @@ class DialingNoPlayPopupScreen(Screen):#正在拨号中...未打出
         self.number_tmp = {}
         self.CALL_LOG_MAX = CALL_LOG_MAX
         self.is_sliding =0
+        self.phone_page_state = 0
+        EventMesh.subscribe("get_phone_state",self.get_phone_state)
 
     def initialization(self):
+        self.phone_page_state = 1
         self.is_sliding =0
         EventMesh.publish("set_UI_high_priority", 1)
         global dialing_popup_screen,dialing_popup_img,dialing_popup_name ,dialing_popup_call,dialing_popup_hangup_imgbtn 
@@ -1879,6 +1989,8 @@ class DialingNoPlayPopupScreen(Screen):#正在拨号中...未打出
         if dialing_popup_name != None:
             name = EventMesh.publish("get_phonename")#获取拨打电话名称
             dialing_popup_name.set_text(name)#名称
+        if dialing_popup_call != None:
+            dialing_popup_call.set_text("正在拨号中")
 
     def post_processor_after_initialization(self):
         self.is_sliding =0
@@ -1948,14 +2060,28 @@ class DialingNoPlayPopupScreen(Screen):#正在拨号中...未打出
         
     def timeout_hangup(self,e):
         EventMesh.publish("system_sleep_rest")#防止黑屏
+        if EventMesh.publish("get_call_state") == 4: #拨通了
+            if dialing_popup_call != None:
+                dialing_popup_call.set_text("正在等待对方接\n听电话")
         self.time_count+=1
-        if self.time_count >= 5 :#设置:#5s内没有打通则不在继续拨打关闭
+        if self.time_count >= 60 :#设置:#5s内没有打通则不在继续拨打关闭
             self.time_count = 0
-            voiceCall.callEnd()
+            self.phone_page_state = 0
+            self.timer1.stop()
+            self.timer2.stop()
             EventMesh.publish("set_UI_high_priority", 0)
-            EventMesh.publish("set_sos_info_call") 
-            # EventMesh.publish("load_screen", {"screen": "dialing"})
-            EventMesh.publish("load_screen", {"screen": "dial_no_connect_popup"})
+            
+            sos_flag = EventMesh.publish("get_sos_flag")
+            print("sos_flag!!!!!!!!!!!!!!!!:",sos_flag)
+            if sos_flag == 1:
+                EventMesh.publish("set_sos_info_call")
+            
+            EventMesh.publish("set_call_state",0)#设置通话状态为0
+            EventMesh.publish("set_interrup_incall",0)
+            EventMesh.publish("set_UI_high_priority",0)
+            EventMesh.publish("return_prev_screen")
+            voiceCall.callEnd()
+            
 
     def hangup(self,e):
         code = e.get_code()
@@ -1964,7 +2090,12 @@ class DialingNoPlayPopupScreen(Screen):#正在拨号中...未打出
             pass
 
         elif  code == lv.EVENT.SHORT_CLICKED:
-            EventMesh.publish("set_UI_high_priority", 0)
+            self.phone_page_state = 0
+            EventMesh.publish("set_call_state",0)
+            EventMesh.publish("set_interrup_incall",0)
+            EventMesh.publish("set_UI_high_priority",0)
+
+            EventMesh.publish("return_prev_screen")
             voiceCall.callEnd()
             sos_flag = EventMesh.publish("get_sos_flag")
             if sos_flag == 1:
@@ -1972,13 +2103,11 @@ class DialingNoPlayPopupScreen(Screen):#正在拨号中...未打出
                 EventMesh.publish("set_sos_flag",0)
                 EventMesh.publish("set_sos_num",0)
                 EventMesh.publish("set_hangup_mode",0)
-            EventMesh.publish("set_interrup_incall",0)
-            EventMesh.publish("set_UI_high_priority",0)
-
-            EventMesh.publish("return_prev_screen")
+            
         
 
     def Close(self):
+        self.phone_page_state = 0
         self.timer1.stop()
         self.timer2.stop()
 
@@ -2949,12 +3078,19 @@ class ToolboxScreen(Screen):
             toolbox_cont.add_style(toolbox_cont_style,lv.PART.MAIN | lv.STATE.DEFAULT)
 
 
-            toolbox_step_bg_img = lv.img(toolbox_cont)
-            toolbox_step_bg_img.set_pos(0, tool_set_y)
-            toolbox_step_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
-            toolbox_step_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
-            toolbox_step_bg_img.set_src("U:/static/list_bg.png")
-            toolbox_step_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+            # toolbox_step_bg_img = lv.img(toolbox_cont)
+            # toolbox_step_bg_img.set_pos(0, tool_set_y)
+            # toolbox_step_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
+            # toolbox_step_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
+            # toolbox_step_bg_img.set_src("U:/static/list_bg.png")
+            # toolbox_step_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+            toolbox_step_bg_img = lv.btn(toolbox_cont)
+            toolbox_step_bg_img.set_pos(int(0),int(tool_set_y))
+            toolbox_step_bg_img.set_size(230,78)
+            toolbox_step_bg_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+            toolbox_step_bg_img.set_style_pad_all(0, lv.STATE.DEFAULT)
+            toolbox_step_bg_img.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
 
 
             toolbox_step_img = lv.img(toolbox_cont)
@@ -2965,12 +3101,19 @@ class ToolboxScreen(Screen):
             toolbox_step_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
             tool_set_y+=TOOL_ICON_OFFSET_SIZE
 
-            toolbox_weather_bg_img = lv.img(toolbox_cont)
-            toolbox_weather_bg_img.set_pos(0, tool_set_y)
-            toolbox_weather_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
-            toolbox_weather_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
-            toolbox_weather_bg_img.set_src("U:/static/list_bg.png")
-            toolbox_weather_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+            # toolbox_weather_bg_img = lv.img(toolbox_cont)
+            # toolbox_weather_bg_img.set_pos(0, tool_set_y)
+            # toolbox_weather_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
+            # toolbox_weather_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
+            # toolbox_weather_bg_img.set_src("U:/static/list_bg.png")
+            # toolbox_weather_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+            toolbox_weather_bg_img = lv.btn(toolbox_cont)
+            toolbox_weather_bg_img.set_pos(int(0),int(tool_set_y))
+            toolbox_weather_bg_img.set_size(230,78)
+            toolbox_weather_bg_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+            toolbox_weather_bg_img.set_style_pad_all(0, lv.STATE.DEFAULT)
+            toolbox_weather_bg_img.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
 
             toolbox_weather_img = lv.img(toolbox_cont)
             toolbox_weather_img.set_pos(8, tool_set_y+6)
@@ -2982,12 +3125,19 @@ class ToolboxScreen(Screen):
             tool_set_y+=TOOL_ICON_OFFSET_SIZE
 
 
-            toolbox_alarm_bg_img = lv.img(toolbox_cont)
-            toolbox_alarm_bg_img.set_pos(0, tool_set_y)
-            toolbox_alarm_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
-            toolbox_alarm_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
-            toolbox_alarm_bg_img.set_src("U:/static/list_bg.png")
-            toolbox_alarm_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+            # toolbox_alarm_bg_img = lv.img(toolbox_cont)
+            # toolbox_alarm_bg_img.set_pos(0, tool_set_y)
+            # toolbox_alarm_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
+            # toolbox_alarm_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
+            # toolbox_alarm_bg_img.set_src("U:/static/list_bg.png")
+            # toolbox_alarm_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+            toolbox_alarm_bg_img = lv.btn(toolbox_cont)
+            toolbox_alarm_bg_img.set_pos(int(0),int(tool_set_y))
+            toolbox_alarm_bg_img.set_size(230,78)
+            toolbox_alarm_bg_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+            toolbox_alarm_bg_img.set_style_pad_all(0, lv.STATE.DEFAULT)
+            toolbox_alarm_bg_img.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
 
             toolbox_alarm_img = lv.img(toolbox_cont)
             toolbox_alarm_img.set_pos(8, tool_set_y+6)
@@ -3006,12 +3156,19 @@ class ToolboxScreen(Screen):
             # toolbox_sms_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
 
             tool_set_y+=TOOL_ICON_OFFSET_SIZE
-            toolbox_countdown_bg_img = lv.img(toolbox_cont)
-            toolbox_countdown_bg_img.set_pos(0, tool_set_y)
-            toolbox_countdown_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
-            toolbox_countdown_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
-            toolbox_countdown_bg_img.set_src("U:/static/list_bg.png")
-            toolbox_countdown_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+            # toolbox_countdown_bg_img = lv.img(toolbox_cont)
+            # toolbox_countdown_bg_img.set_pos(0, tool_set_y)
+            # toolbox_countdown_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
+            # toolbox_countdown_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
+            # toolbox_countdown_bg_img.set_src("U:/static/list_bg.png")
+            # toolbox_countdown_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+            toolbox_countdown_bg_img = lv.btn(toolbox_cont)
+            toolbox_countdown_bg_img.set_pos(int(0),int(tool_set_y))
+            toolbox_countdown_bg_img.set_size(230,78)
+            toolbox_countdown_bg_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+            toolbox_countdown_bg_img.set_style_pad_all(0, lv.STATE.DEFAULT)
+            toolbox_countdown_bg_img.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
 
             toolbox_countdown_img = lv.img(toolbox_cont)
             toolbox_countdown_img.set_pos(8, tool_set_y+6)
@@ -3022,12 +3179,19 @@ class ToolboxScreen(Screen):
 
             tool_set_y+=TOOL_ICON_OFFSET_SIZE
 
-            toolbox_stopwatch_bg_img = lv.img(toolbox_cont)
-            toolbox_stopwatch_bg_img.set_pos(0, tool_set_y)
-            toolbox_stopwatch_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
-            toolbox_stopwatch_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
-            toolbox_stopwatch_bg_img.set_src("U:/static/list_bg.png")
-            toolbox_stopwatch_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+            # toolbox_stopwatch_bg_img = lv.img(toolbox_cont)
+            # toolbox_stopwatch_bg_img.set_pos(0, tool_set_y)
+            # toolbox_stopwatch_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
+            # toolbox_stopwatch_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
+            # toolbox_stopwatch_bg_img.set_src("U:/static/list_bg.png")
+            # toolbox_stopwatch_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+            toolbox_stopwatch_bg_img = lv.btn(toolbox_cont)
+            toolbox_stopwatch_bg_img.set_pos(int(0),int(tool_set_y))
+            toolbox_stopwatch_bg_img.set_size(230,78)
+            toolbox_stopwatch_bg_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+            toolbox_stopwatch_bg_img.set_style_pad_all(0, lv.STATE.DEFAULT)
+            toolbox_stopwatch_bg_img.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
 
             toolbox_stopwatch_img = lv.img(toolbox_cont)
             toolbox_stopwatch_img.set_pos(8, tool_set_y+6)
@@ -3314,19 +3478,14 @@ class IncomingCallScreen(Screen):
     def hangup_cb(self,e):
         code = e.get_code()
         if  code == lv.EVENT.SHORT_CLICKED:
-            #utime.sleep_ms(10)
-            EventMesh.publish("set_UI_high_priority", 0)
             self.aud.stop()
             self.call_timer.stop()
-            voiceCall.callEnd()
+            EventMesh.publish("set_call_state",0)
             EventMesh.publish("set_interrup_incall",0)
             EventMesh.publish("set_UI_high_priority",0)
-            
-
-            screen_NAME = EventMesh.publish("get_screen_NAME")
-            if screen_NAME != None:
-                if screen_NAME != "dialing_noplay_popup":
-                    EventMesh.publish("return_prev_screen")
+            EventMesh.publish("return_prev_screen")
+            voiceCall.callEnd()
+           
 
     def btn1_release(self):
         pass
@@ -3946,16 +4105,15 @@ class OnCallScreen(Screen):
     def hangup(self,e):
         code = e.get_code()
         if  code == lv.EVENT.SHORT_CLICKED:
-            EventMesh.publish("set_UI_high_priority", 0)
+            
             self.timer.stop()
-            voiceCall.callEnd()
+            EventMesh.publish("set_call_state",0)
+            EventMesh.publish("set_UI_high_priority", 0)
             EventMesh.publish("set_interrup_incall",0)
             EventMesh.publish("set_UI_high_priority",0)
+            EventMesh.publish("return_prev_screen")
+            voiceCall.callEnd()
             
-            screen_NAME = EventMesh.publish("get_screen_NAME")
-            if screen_NAME != None:
-                if screen_NAME != "dialing_noplay_popup":
-                    EventMesh.publish("return_prev_screen")
             
        
 
@@ -4067,6 +4225,7 @@ weather_detail_label = None
 weather_location_label = None
 no_connect_label = None
 no_connect_label1 = None
+weather_type_label = None
 class WeatherScreen(Screen):
     NAME = "weather"
     
@@ -4077,7 +4236,7 @@ class WeatherScreen(Screen):
         EventMesh.subscribe("updata_weather_show", self.update_weather_data)
 
     def initialization(self):
-        global weather_screen,weather_img,no_weather_img,weather_tem_label,no_weather_degree,\
+        global weather_screen,weather_img,weather_type_label,no_weather_img,weather_tem_label,no_weather_degree,\
             weather_detail_label,weather_location_label,no_connect_label ,no_connect_label1 
         if weather_screen == None :
             weather_screen = lv.obj()
@@ -4085,11 +4244,19 @@ class WeatherScreen(Screen):
             weather_screen.add_style(style_screen, lv.PART.MAIN | lv.STATE.DEFAULT)
             weather_screen.add_event_cb(lambda e:EventMesh.callback_wrapper(self.fun(e)), lv.EVENT.GESTURE, None)
 
-            weather_img = lv.img(weather_screen)
-            weather_img.set_pos(10, 10)
-            weather_img.set_size(135, 120)
+            weather_type_label = lv.label(weather_screen)
+            weather_type_label.set_pos(10, 10)
+            weather_type_label.set_size(135, 120)
+            weather_type_label.set_text(" ")
+            weather_type_label.set_long_mode(lv.label.LONG.WRAP)
+            weather_type_label.set_style_text_align(lv.TEXT_ALIGN.CENTER, 0)
+            weather_type_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
 
-            weather_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+            # weather_img = lv.img(weather_screen)
+            # weather_img.set_pos(10, 10)
+            # weather_img.set_size(135, 120)
+
+            # weather_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
 
             no_weather_img = lv.img(weather_screen)
             no_weather_img.set_pos(10, 10)
@@ -4160,15 +4327,31 @@ class WeatherScreen(Screen):
                 no_data = self.weather_data[8]
                 if no_data != 0 :
                     no_weather_img.add_flag(lv.obj.FLAG.HIDDEN)
-                    weather_img.clear_flag(lv.obj.FLAG.HIDDEN)
+                    weather_type_label.clear_flag(lv.obj.FLAG.HIDDEN)
+                    # weather_img.clear_flag(lv.obj.FLAG.HIDDEN)
                     no_connect_label.set_text(" ")
                     no_connect_label1.set_text(" ")
                     # print("self.weather_data:{}".format(self.weather_data))
                     type = self.weather_data[3]
                     if type == None:
-                        weather_img.set_src("U:/static/update.png")#天气类型
+                        weather_type_label.add_flag(lv.obj.FLAG.HIDDEN)
+                        no_weather_img.clear_flag(lv.obj.FLAG.HIDDEN)
+                        # weather_img.set_src("U:/static/update.png")#天气类型
                     else:
-                        weather_img.set_src("U:/static/{}_weather.png".format(type))#天气类型
+                        no_weather_img.add_flag(lv.obj.FLAG.HIDDEN)
+                        weather_type_label.clear_flag(lv.obj.FLAG.HIDDEN)
+                        if type == 0: #晴
+                            weather_type_label.set_text("晴")
+                        elif type == 1: #阴
+                            weather_type_label.set_text("阴")
+                        elif type == 2: #雨
+                            weather_type_label.set_text("雨")
+                        elif type == 3: #雪
+                            weather_type_label.set_text("雪")
+                        else:
+                            weather_type_label.set_text(" ")
+
+                        # weather_img.set_src("U:/static/{}_weather.png".format(type))#天气类型
 
                     temp = self.weather_data[4]
                     if temp == None:
@@ -4203,7 +4386,7 @@ class WeatherScreen(Screen):
                 weather_tem_label.set_text("_ _℃")
                 
                 no_weather_img.clear_flag(lv.obj.FLAG.HIDDEN)
-                weather_img.add_flag(lv.obj.FLAG.HIDDEN)
+                weather_type_label.add_flag(lv.obj.FLAG.HIDDEN)
                 no_connect_label.set_text("找不到服务器")
                 no_connect_label1.set_text("请联网后重试")
 
@@ -5531,11 +5714,21 @@ class UIFINDScreen(Screen):
             #进入图片
             watchface_mpsignal_img = lv.img(FIND_screen)
             watchface_mpsignal_img.set_pos(int(40),int(27))
-            watchface_mpsignal_img.set_size(160,230)
+            watchface_mpsignal_img.set_size(158,158)
             watchface_mpsignal_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
             watchface_mpsignal_img.add_flag(lv.obj.FLAG.CLICKABLE)
             watchface_mpsignal_img.set_src("U:/static/find_phone.png")
             watchface_mpsignal_img.add_style(style_screen, lv.PART.MAIN|lv.STATE.DEFAULT)
+
+            countdown_end_label = lv.label(FIND_screen)
+            countdown_end_label.set_pos(0, 220)
+            countdown_end_label.set_size(LCD_SIZE_W, 40)
+            countdown_end_label.set_text("点击屏幕关闭")
+            countdown_end_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
+            countdown_end_label.set_long_mode(lv.label.LONG.WRAP)
+            countdown_end_label.set_style_text_align(lv.TEXT_ALIGN.CENTER, 0)
+
+
             self.meta = FIND_screen
         
 
@@ -5611,11 +5804,20 @@ class LowPowerScreen(Screen):
             #进入图片
             Lowpower_screen_img = lv.img(Lowpower_screen)
             Lowpower_screen_img.set_pos(int(40),int(27))
-            Lowpower_screen_img.set_size(160,230)
+            Lowpower_screen_img.set_size(158,158)
             Lowpower_screen_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
             Lowpower_screen_img.add_flag(lv.obj.FLAG.CLICKABLE)
             Lowpower_screen_img.set_src("U:/static/low_power.png")
             Lowpower_screen_img.add_style(style_screen, lv.PART.MAIN|lv.STATE.DEFAULT)
+
+            countdown_end_label = lv.label(Lowpower_screen)
+            countdown_end_label.set_pos(0, 220)
+            countdown_end_label.set_size(LCD_SIZE_W, 40)
+            countdown_end_label.set_text("低电量")
+            countdown_end_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
+            countdown_end_label.set_long_mode(lv.label.LONG.WRAP)
+            countdown_end_label.set_style_text_align(lv.TEXT_ALIGN.CENTER, 0)
+
             self.meta = Lowpower_screen
 
     
@@ -5770,41 +5972,105 @@ class sosScreen(Screen):
             sos_screen_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
 
 
-            sos_screen_confirm_img = lv.img(sos_screen)
-            sos_screen_confirm_img.set_size(176, 46)
-            sos_screen_confirm_img.set_pos(32, 170)
-            sos_screen_confirm_img.set_src("U:/static/off_icon.png")
-            sos_screen_confirm_img.add_flag(lv.obj.FLAG.CLICKABLE)
-            sos_screen_confirm_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
-
-            sos_screen_confirm_label = lv.label(sos_screen_confirm_img)
-            sos_screen_confirm_label.set_text("确定")
-            sos_screen_confirm_label.align(lv.ALIGN.CENTER, 0, 5)
-            sos_screen_confirm_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
-
-            sos_screen_return = lv.img(sos_screen)
-            sos_screen_return.set_size(176, 46)
-            sos_screen_return.set_pos(32, 230)
-            sos_screen_return.set_src("U:/static/cancel_icon.png")
-            sos_screen_return.add_flag(lv.obj.FLAG.CLICKABLE)
-            sos_screen_return.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
-            sos_screen_return_label = lv.label(sos_screen_return)
-            sos_screen_return_label.set_text("取消")
-            sos_screen_return_label.align(lv.ALIGN.CENTER, 0, 5)
-            sos_screen_return_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
-            sos_screen_return_label.set_ext_click_area(20)
+            # sos_screen_confirm_img = lv.img(sos_screen)
+            # sos_screen_confirm_img.set_size(176, 46)
+            # sos_screen_confirm_img.set_pos(32, 170)
+            # sos_screen_confirm_img.set_src("U:/static/off_icon.png")
+            # sos_screen_confirm_img.add_flag(lv.obj.FLAG.CLICKABLE)
+            # sos_screen_confirm_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+            # sos_screen_confirm_label = lv.label(sos_screen_confirm_img)
+            # sos_screen_confirm_label.set_text("确定")
+            # sos_screen_confirm_label.align(lv.ALIGN.CENTER, 0, 5)
+            # sos_screen_confirm_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+            sos_screen_confirm_img = lv.btn(no_sim_auto_screen)
+            sos_screen_confirm_img.set_pos(int(32),int(46))
+            sos_screen_confirm_img.set_size(176,46)
+            sos_screen_confirm_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+            screen_btn_1_label = lv.label(sos_screen_confirm_img)
+            screen_btn_1_label.set_text("确定")
+            sos_screen_confirm_img.set_style_pad_all(0, lv.STATE.DEFAULT)
+            screen_btn_1_label.align(lv.ALIGN.CENTER,0,0)
+            # create style style_screen_btn_1_main_main_default
+            style_screen_btn_1_main_main_default = lv.style_t()
+            style_screen_btn_1_main_main_default.init()
+            style_screen_btn_1_main_main_default.set_radius(20)
+            style_screen_btn_1_main_main_default.set_bg_color(lv.color_make(249,47,109))
+            style_screen_btn_1_main_main_default.set_bg_grad_color(lv.color_make(249,47,109))
+            style_screen_btn_1_main_main_default.set_bg_grad_dir(lv.GRAD_DIR.NONE)
+            style_screen_btn_1_main_main_default.set_bg_opa(255)
+            style_screen_btn_1_main_main_default.set_border_color(lv.color_make(249,47,109))
+            style_screen_btn_1_main_main_default.set_border_width(0)
+            style_screen_btn_1_main_main_default.set_border_opa(255)
+            style_screen_btn_1_main_main_default.set_text_color(lv.color_make(0xff,0xff,0xff))
+            style_screen_btn_1_main_main_default.set_text_font(lv.K01_font_16_ALL)
+            style_screen_btn_1_main_main_default.set_text_align(lv.TEXT_ALIGN.CENTER)
+
+            # add style for screen_btn_1
+            sos_screen_confirm_img.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
+
+            # sos_screen_return = lv.img(sos_screen)
+            # sos_screen_return.set_size(176, 46)
+            # sos_screen_return.set_pos(32, 230)
+            # sos_screen_return.set_src("U:/static/cancel_icon.png")
+            # sos_screen_return.add_flag(lv.obj.FLAG.CLICKABLE)
+            # sos_screen_return.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+            # sos_screen_return_label = lv.label(sos_screen_return)
+            # sos_screen_return_label.set_text("取消")
+            # sos_screen_return_label.align(lv.ALIGN.CENTER, 0, 5)
+            # sos_screen_return_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
+            # sos_screen_return_label.set_ext_click_area(20)
+
+            sos_screen_return = lv.btn(sos_screen)
+            sos_screen_return.set_pos(int(32),int(230))
+            sos_screen_return.set_size(176,46)
+            sos_screen_return.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+            screen_btn_1_label = lv.label(sos_screen_return)
+            screen_btn_1_label.set_text("取消")
+            sos_screen_return.set_style_pad_all(0, lv.STATE.DEFAULT)
+            screen_btn_1_label.align(lv.ALIGN.CENTER,0,0)
+            # create style style_screen_btn_1_main_main_default
+            style_screen_btn_1_main_main_default = lv.style_t()
+            style_screen_btn_1_main_main_default.init()
+            style_screen_btn_1_main_main_default.set_radius(20)
+            style_screen_btn_1_main_main_default.set_bg_color(lv.color_make(7,222,169))
+            style_screen_btn_1_main_main_default.set_bg_grad_color(lv.color_make(7,222,169))
+            style_screen_btn_1_main_main_default.set_bg_grad_dir(lv.GRAD_DIR.NONE)
+            style_screen_btn_1_main_main_default.set_bg_opa(255)
+            style_screen_btn_1_main_main_default.set_border_color(lv.color_make(7,222,169))
+            style_screen_btn_1_main_main_default.set_border_width(0)
+            style_screen_btn_1_main_main_default.set_border_opa(255)
+            style_screen_btn_1_main_main_default.set_text_color(lv.color_make(0xff,0xff,0xff))
+            style_screen_btn_1_main_main_default.set_text_font(lv.K01_font_16_ALL)
+            style_screen_btn_1_main_main_default.set_text_align(lv.TEXT_ALIGN.CENTER)
+
+            # add style for screen_btn_1
+            sos_screen_return.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
 
             self.meta = sos_screen
-            sos_screen_confirm_img.add_event_cb(lambda e: EventMesh.callback_wrapper(self.timer_comfirm_cb(e)),
+            sos_screen.add_event_cb(lambda e:EventMesh.callback_wrapper(self.button_cb(e,0)), lv.EVENT.GESTURE, None)
+            sos_screen_confirm_img.add_event_cb(lambda e: EventMesh.callback_wrapper(self.button_cb(e,1)),
                                      lv.EVENT.SHORT_CLICKED, None)
             
-            sos_screen_return.add_event_cb(lambda e: EventMesh.callback_wrapper(self.timer_cancel_cb(e)),
+            sos_screen_return.add_event_cb(lambda e: EventMesh.callback_wrapper(self.button_cb(e,2)),
                                      lv.EVENT.SHORT_CLICKED, None)
-            sos_screen_confirm_img.add_event_cb(lambda e: EventMesh.callback_wrapper(self.timer_comfirm_cb(e)),
-                                     lv.EVENT.PRESSING, None)
             
-            sos_screen_return.add_event_cb(lambda e: EventMesh.callback_wrapper(self.timer_cancel_cb(e)),
-                                     lv.EVENT.PRESSING, None)
+
+    def button_cb(self,e,msg):
+        code = e.get_code()
+        indev = lv.indev_get_act()
+        lv.indev_t.wait_release(indev)
+        dir = lv.indev_t.get_gesture_dir(indev)
+        if code == lv.EVENT.GESTURE:
+            if dir == lv.DIR.RIGHT:
+                EventMesh.publish("return_prev_screen")
+
+        elif  code == lv.EVENT.SHORT_CLICKED:
+            if msg != 0:
+                if msg == 1:
+                    EventMesh.publish("set_sos_flag", 1)
+                
 
     def timer_comfirm_cb(self,e):
         code = e.get_code()
index 6640cfa..08097f4 100644 (file)
@@ -25,7 +25,17 @@ style_volume_btn.set_shadow_opa(0)
 style_volume_btn.set_border_width(0)
 style_volume_btn.set_bg_color(lv.color_make(0x80, 0x80, 0x80))
 
-
+style_screen_btn_1_main_main_default = lv.style_t()
+style_screen_btn_1_main_main_default.init()
+style_screen_btn_1_main_main_default.set_radius(10)
+style_screen_btn_1_main_main_default.set_bg_color(lv.color_make(0x33,0x33,0x33))
+style_screen_btn_1_main_main_default.set_bg_grad_color(lv.color_make(0x21,0x95,0xf6))
+style_screen_btn_1_main_main_default.set_bg_grad_dir(lv.GRAD_DIR.NONE)
+style_screen_btn_1_main_main_default.set_bg_opa(255)
+style_screen_btn_1_main_main_default.set_border_color(lv.color_make(0x33,0x33,0x33))
+style_screen_btn_1_main_main_default.set_border_width(0)
+style_screen_btn_1_main_main_default.set_border_opa(255)
+style_screen_btn_1_main_main_default.set_text_color(lv.color_make(0xff,0x00,0x00))
 
 setting_cont_y = 0
 setting_screen = lv.obj()
@@ -82,36 +92,50 @@ setting_cont.add_style(setting_cont_style,lv.PART.MAIN | lv.STATE.DEFAULT)
 # setting_language_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
 #setting_cont_y += 60
 
-setting_dialswitch_bg_img = lv.img(setting_cont)
-setting_dialswitch_bg_img.set_pos(0, setting_cont_y)
-setting_dialswitch_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
-setting_dialswitch_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
-setting_dialswitch_bg_img.set_src("U:/static/list_bg.png")
-setting_dialswitch_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
-
-setting_dialswitch_img = lv.img(setting_cont)
-setting_dialswitch_img.set_pos(8, setting_cont_y+6)
-setting_dialswitch_img.set_size(SETTING_ICON_W_SIZE, SETTING_ICON_H_SIZE)
-# setting_dialswitch_img.add_flag(lv.obj.FLAG.CLICKABLE)
-setting_dialswitch_img.set_src("U:/static/setting/menu_watch_switch.png")
-setting_dialswitch_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
-setting_cont_y+=SETTING_ICON_OFFSET_SIZE
-
-
-setting_themeswitch_bg_img = lv.img(setting_cont)
-setting_themeswitch_bg_img.set_pos(0, setting_cont_y)
-setting_themeswitch_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
-setting_themeswitch_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
-setting_themeswitch_bg_img.set_src("U:/static/list_bg.png")
-setting_themeswitch_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+# setting_dialswitch_bg_img = lv.img(setting_cont)
+# setting_dialswitch_bg_img.set_pos(0, setting_cont_y)
+# setting_dialswitch_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
+# setting_dialswitch_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
+# setting_dialswitch_bg_img.set_src("U:/static/list_bg.png")
+# setting_dialswitch_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+# setting_dialswitch_bg_img = lv.btn(setting_cont)
+# setting_dialswitch_bg_img.set_pos(int(5),int(setting_cont_y))
+# setting_dialswitch_bg_img.set_size(230,78)
+# setting_dialswitch_bg_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+# setting_dialswitch_bg_img.set_style_pad_all(0, lv.STATE.DEFAULT)
+# setting_dialswitch_bg_img.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
+
+# setting_dialswitch_img = lv.img(setting_cont)
+# setting_dialswitch_img.set_pos(8, setting_cont_y+6)
+# setting_dialswitch_img.set_size(SETTING_ICON_W_SIZE, SETTING_ICON_H_SIZE)
+# # setting_dialswitch_img.add_flag(lv.obj.FLAG.CLICKABLE)
+# setting_dialswitch_img.set_src("U:/static/setting/menu_watch_switch.png")
+# setting_dialswitch_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+# setting_cont_y+=SETTING_ICON_OFFSET_SIZE
+
+
+# setting_themeswitch_bg_img = lv.img(setting_cont)
+# setting_themeswitch_bg_img.set_pos(0, setting_cont_y)
+# setting_themeswitch_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
+# setting_themeswitch_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
+# setting_themeswitch_bg_img.set_src("U:/static/list_bg.png")
+# setting_themeswitch_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+# setting_themeswitch_bg_img = lv.btn(setting_cont)
+# setting_themeswitch_bg_img.set_pos(int(0),int(setting_cont_y))
+# setting_themeswitch_bg_img.set_size(230,78)
+# setting_themeswitch_bg_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+# setting_themeswitch_bg_img.set_style_pad_all(0, lv.STATE.DEFAULT)
+# setting_themeswitch_bg_img.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
 
-setting_themeswitch_img = lv.img(setting_cont)
-setting_themeswitch_img.set_pos(8, setting_cont_y+6)
-setting_themeswitch_img.set_size(SETTING_ICON_W_SIZE, SETTING_ICON_H_SIZE)
-# setting_themeswitch_img.add_flag(lv.obj.FLAG.CLICKABLE)
-setting_themeswitch_img.set_src("U:/static/setting/menu_theme_menustyle.png")
-setting_themeswitch_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
-setting_cont_y+=SETTING_ICON_OFFSET_SIZE
+# setting_themeswitch_img = lv.img(setting_cont)
+# setting_themeswitch_img.set_pos(8, setting_cont_y+6)
+# setting_themeswitch_img.set_size(SETTING_ICON_W_SIZE, SETTING_ICON_H_SIZE)
+# # setting_themeswitch_img.add_flag(lv.obj.FLAG.CLICKABLE)
+# setting_themeswitch_img.set_src("U:/static/setting/menu_theme_menustyle.png")
+# setting_themeswitch_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+# setting_cont_y+=SETTING_ICON_OFFSET_SIZE
 
 # setting_themeswitch = lv.btn(setting_cont)
 # setting_themeswitch.set_pos(0, 120)
@@ -130,12 +154,22 @@ setting_cont_y+=SETTING_ICON_OFFSET_SIZE
 # setting_themeswitch_img.set_src("U:/static/menu_theme_switch.png")
 # setting_themeswitch_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
 #setting_cont_y+=60
-setting_imei_bg_img = lv.img(setting_cont)
-setting_imei_bg_img.set_pos(0, setting_cont_y)
-setting_imei_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
-setting_imei_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
-setting_imei_bg_img.set_src("U:/static/list_bg.png")
-setting_imei_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+# setting_imei_bg_img = lv.img(setting_cont)
+# setting_imei_bg_img.set_pos(0, setting_cont_y)
+# setting_imei_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
+# setting_imei_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
+# setting_imei_bg_img.set_src("U:/static/list_bg.png")
+# setting_imei_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+setting_imei_bg_img = lv.btn(setting_cont)
+setting_imei_bg_img.set_pos(int(0),int(setting_cont_y))
+setting_imei_bg_img.set_size(230,78)
+setting_imei_bg_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+setting_imei_bg_img.set_style_pad_all(0, lv.STATE.DEFAULT)
+# create style style_screen_btn_1_main_main_default
+# add style for screen_btn_1
+setting_imei_bg_img.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
 
 setting_imei_img = lv.img(setting_cont)
 setting_imei_img.set_pos(8, setting_cont_y+6)
@@ -145,12 +179,19 @@ setting_imei_img.set_src("U:/static/setting/menu_imei_qrcode.png")
 setting_imei_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
 setting_cont_y+=SETTING_ICON_OFFSET_SIZE
 
-setting_app_bg_img = lv.img(setting_cont)
-setting_app_bg_img.set_pos(0, setting_cont_y)
-setting_app_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
-setting_app_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
-setting_app_bg_img.set_src("U:/static/list_bg.png")
-setting_app_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+setting_app_bg_img = lv.btn(setting_cont)
+setting_app_bg_img.set_pos(int(0),int(setting_cont_y))
+setting_app_bg_img.set_size(230,78)
+setting_app_bg_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+setting_app_bg_img.set_style_pad_all(0, lv.STATE.DEFAULT)
+setting_app_bg_img.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
+# setting_app_bg_img = lv.img(setting_cont)
+# setting_app_bg_img.set_pos(0, setting_cont_y)
+# setting_app_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
+# setting_app_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
+# setting_app_bg_img.set_src("U:/static/list_bg.png")
+# setting_app_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
 
 setting_app_img = lv.img(setting_cont)
 setting_app_img.set_pos(8, setting_cont_y+6)
@@ -160,12 +201,19 @@ setting_app_img.set_src("U:/static/setting/menu_app_qrcode.png")
 setting_app_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
 setting_cont_y+=SETTING_ICON_OFFSET_SIZE
 
-setting_bright_bg_img = lv.img(setting_cont)
-setting_bright_bg_img.set_pos(0, setting_cont_y)
-setting_bright_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
-setting_bright_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
-setting_bright_bg_img.set_src("U:/static/list_bg.png")
-setting_bright_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+# setting_bright_bg_img = lv.img(setting_cont)
+# setting_bright_bg_img.set_pos(0, setting_cont_y)
+# setting_bright_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
+# setting_bright_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
+# setting_bright_bg_img.set_src("U:/static/list_bg.png")
+# setting_bright_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+setting_bright_bg_img = lv.btn(setting_cont)
+setting_bright_bg_img.set_pos(int(0),int(setting_cont_y))
+setting_bright_bg_img.set_size(230,78)
+setting_bright_bg_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+setting_bright_bg_img.set_style_pad_all(0, lv.STATE.DEFAULT)
+setting_bright_bg_img.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
 
 setting_bright_img = lv.img(setting_cont)
 setting_bright_img.set_pos(8, setting_cont_y+6)
@@ -175,12 +223,18 @@ setting_bright_img.set_src("U:/static/setting/menu_bright.png")
 setting_bright_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
 setting_cont_y+=SETTING_ICON_OFFSET_SIZE
 
-setting_volume_bg_img = lv.img(setting_cont)
-setting_volume_bg_img.set_pos(0, setting_cont_y)
-setting_volume_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
-setting_volume_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
-setting_volume_bg_img.set_src("U:/static/list_bg.png")
-setting_volume_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+# setting_volume_bg_img = lv.img(setting_cont)
+# setting_volume_bg_img.set_pos(0, setting_cont_y)
+# setting_volume_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
+# setting_volume_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
+# setting_volume_bg_img.set_src("U:/static/list_bg.png")
+# setting_volume_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+setting_volume_bg_img = lv.btn(setting_cont)
+setting_volume_bg_img.set_pos(int(0),int(setting_cont_y))
+setting_volume_bg_img.set_size(230,78)
+setting_volume_bg_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+setting_volume_bg_img.set_style_pad_all(0, lv.STATE.DEFAULT)
+setting_volume_bg_img.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
 
 setting_volume_img = lv.img(setting_cont)
 setting_volume_img.set_pos(8, setting_cont_y+6)
@@ -190,12 +244,19 @@ setting_volume_img.set_src("U:/static/setting/menu_volume.png")
 setting_volume_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
 setting_cont_y+=SETTING_ICON_OFFSET_SIZE
 
-setting_restore_bg_img = lv.img(setting_cont)
-setting_restore_bg_img.set_pos(0, setting_cont_y)
-setting_restore_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
-setting_restore_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
-setting_restore_bg_img.set_src("U:/static/list_bg.png")
-setting_restore_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+# setting_restore_bg_img = lv.img(setting_cont)
+# setting_restore_bg_img.set_pos(0, setting_cont_y)
+# setting_restore_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
+# setting_restore_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
+# setting_restore_bg_img.set_src("U:/static/list_bg.png")
+# setting_restore_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+setting_restore_bg_img = lv.btn(setting_cont)
+setting_restore_bg_img.set_pos(int(0),int(setting_cont_y))
+setting_restore_bg_img.set_size(230,78)
+setting_restore_bg_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+setting_restore_bg_img.set_style_pad_all(0, lv.STATE.DEFAULT)
+setting_restore_bg_img.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
 
 setting_restore_img = lv.img(setting_cont)
 setting_restore_img.set_pos(8, setting_cont_y+6)
@@ -205,12 +266,19 @@ setting_restore_img.set_src("U:/static/setting/menu_restore.png")
 setting_restore_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
 setting_cont_y+=SETTING_ICON_OFFSET_SIZE
 
-setting_poweroff_bg_img = lv.img(setting_cont)
-setting_poweroff_bg_img.set_pos(0, setting_cont_y)
-setting_poweroff_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
-setting_poweroff_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
-setting_poweroff_bg_img.set_src("U:/static/list_bg.png")
-setting_poweroff_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+# setting_poweroff_bg_img = lv.img(setting_cont)
+# setting_poweroff_bg_img.set_pos(0, setting_cont_y)
+# setting_poweroff_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
+# setting_poweroff_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
+# setting_poweroff_bg_img.set_src("U:/static/list_bg.png")
+# setting_poweroff_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+setting_poweroff_bg_img = lv.btn(setting_cont)
+setting_poweroff_bg_img.set_pos(int(0),int(setting_cont_y))
+setting_poweroff_bg_img.set_size(230,78)
+setting_poweroff_bg_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+setting_poweroff_bg_img.set_style_pad_all(0, lv.STATE.DEFAULT)
+setting_poweroff_bg_img.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
 
 setting_poweroff_img = lv.img(setting_cont)
 setting_poweroff_img.set_pos(8, setting_cont_y+6)
@@ -220,12 +288,19 @@ setting_poweroff_img.set_src("U:/static/setting/menu_poweroff.png")
 setting_poweroff_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
 setting_cont_y+=SETTING_ICON_OFFSET_SIZE
 
-setting_version_bg_img = lv.img(setting_cont)
-setting_version_bg_img.set_pos(0, setting_cont_y)
-setting_version_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
-setting_version_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
-setting_version_bg_img.set_src("U:/static/list_bg.png")
-setting_version_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+# setting_version_bg_img = lv.img(setting_cont)
+# setting_version_bg_img.set_pos(0, setting_cont_y)
+# setting_version_bg_img.set_size(TOOL_BG_ICON_W_SIZE, TOOL_BG_ICON_H_SIZE)
+# setting_version_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
+# setting_version_bg_img.set_src("U:/static/list_bg.png")
+# setting_version_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+setting_version_bg_img = lv.btn(setting_cont)
+setting_version_bg_img.set_pos(int(0),int(setting_cont_y))
+setting_version_bg_img.set_size(230,78)
+setting_version_bg_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+setting_version_bg_img.set_style_pad_all(0, lv.STATE.DEFAULT)
+setting_version_bg_img.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
 
 setting_version_img = lv.img(setting_cont)
 setting_version_img.set_pos(8, setting_cont_y+6)
@@ -260,8 +335,8 @@ class SettingScreen(Screen):
         setting_screen.add_event_cb(lambda e:EventMesh.callback_wrapper(self.setting_cb(e,"void")), lv.EVENT.GESTURE, None)
         # img regist btton
         # setting_language.add_event_cb(lambda e: self.load_screen(e, {"screen": "language"}), lv.EVENT.CLICKED, None)
-        setting_dialswitch_bg_img.add_event_cb(lambda e: EventMesh.callback_wrapper(self.setting_cb(e, "dialswitch")), lv.EVENT.SHORT_CLICKED, None)
-        setting_themeswitch_bg_img.add_event_cb(lambda e: EventMesh.callback_wrapper(self.setting_cb(e, "themeswitch")), lv.EVENT.SHORT_CLICKED, None)
+        # setting_dialswitch_bg_img.add_event_cb(lambda e: EventMesh.callback_wrapper(self.setting_cb(e, "dialswitch")), lv.EVENT.SHORT_CLICKED, None)
+        # setting_themeswitch_bg_img.add_event_cb(lambda e: EventMesh.callback_wrapper(self.setting_cb(e, "themeswitch")), lv.EVENT.SHORT_CLICKED, None)
         setting_imei_bg_img.add_event_cb(lambda e: EventMesh.callback_wrapper(self.setting_cb(e, "imei")), lv.EVENT.SHORT_CLICKED, None)
         setting_app_bg_img.add_event_cb(lambda e: EventMesh.callback_wrapper(self.setting_cb(e, "app")), lv.EVENT.SHORT_CLICKED, None)
         setting_bright_bg_img.add_event_cb(lambda e:EventMesh.callback_wrapper( self.setting_cb(e, "brightness")), lv.EVENT.SHORT_CLICKED, None)
@@ -439,12 +514,19 @@ menustyle_title.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT
 
 
 
-menustyle_img1_bg_img = lv.img(menustyle_screen)
-menustyle_img1_bg_img.set_pos(5, 54)
-menustyle_img1_bg_img.set_size(230, 78)
-menustyle_img1_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
-menustyle_img1_bg_img.set_src("U:/static/list_bg.png")
-menustyle_img1_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+# menustyle_img1_bg_img = lv.img(menustyle_screen)
+# menustyle_img1_bg_img.set_pos(5, 54)
+# menustyle_img1_bg_img.set_size(230, 78)
+# menustyle_img1_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
+# menustyle_img1_bg_img.set_src("U:/static/list_bg.png")
+# menustyle_img1_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+menustyle_img1_bg_img = lv.btn(menustyle_screen)
+menustyle_img1_bg_img.set_pos(int(0),int(54))
+menustyle_img1_bg_img.set_size(230,78)
+menustyle_img1_bg_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+menustyle_img1_bg_img.set_style_pad_all(0, lv.STATE.DEFAULT)
+menustyle_img1_bg_img.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
 
 
 menustyle_btn1_label = lv.label(menustyle_img1_bg_img)
@@ -465,12 +547,19 @@ menustyle_btn1_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DE
 # brightness_flip_sw1.set_size(80, 39)
 
 
-menustyle_img2_bg_img = lv.img(menustyle_screen)
-menustyle_img2_bg_img.set_pos(5, 139)
-menustyle_img2_bg_img.set_size(230, 78)
-menustyle_img2_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
-menustyle_img2_bg_img.set_src("U:/static/list_bg.png")
-menustyle_img2_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+# menustyle_img2_bg_img = lv.img(menustyle_screen)
+# menustyle_img2_bg_img.set_pos(5, 139)
+# menustyle_img2_bg_img.set_size(230, 78)
+# menustyle_img2_bg_img.add_flag(lv.obj.FLAG.CLICKABLE)
+# menustyle_img2_bg_img.set_src("U:/static/list_bg.png")
+# menustyle_img2_bg_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+menustyle_img2_bg_img = lv.btn(menustyle_screen)
+menustyle_img2_bg_img.set_pos(int(0),int(139))
+menustyle_img2_bg_img.set_size(230,78)
+menustyle_img2_bg_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+menustyle_img2_bg_img.set_style_pad_all(0, lv.STATE.DEFAULT)
+menustyle_img2_bg_img.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
 
 menustyle_btn1_label = lv.label(menustyle_img2_bg_img)
 menustyle_btn1_label.set_text("单页")
@@ -1063,30 +1152,83 @@ poweroff_label.set_size(240, 20)
 poweroff_label.set_pos(0,120)
 poweroff_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
 
-poweroff_confirm_img = lv.img(poweroff_screen)
-poweroff_confirm_img.set_size(176, 46)
-poweroff_confirm_img.set_pos(32, 160)
-poweroff_confirm_img.set_src("U:/static/off_icon.png")
-poweroff_confirm_img.add_flag(lv.obj.FLAG.CLICKABLE)
-poweroff_confirm_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
-
-poweroff_confirm_label = lv.label(poweroff_confirm_img)
-poweroff_confirm_label.set_text("关机")
-poweroff_confirm_label.align(lv.ALIGN.CENTER, 0, 5)
-poweroff_confirm_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
-
-poweroff_return = lv.img(poweroff_screen)
-poweroff_return.set_size(176, 46)
-poweroff_return.set_pos(32, 230)
-poweroff_return.set_src("U:/static/cancel_icon.png")
-poweroff_return.add_flag(lv.obj.FLAG.CLICKABLE)
-poweroff_return.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
-poweroff_return_label = lv.label(poweroff_return)
-poweroff_return_label.set_text("返回")
-poweroff_return_label.align(lv.ALIGN.CENTER, 0, 5)
-poweroff_return_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
-poweroff_return.set_ext_click_area(20)
 
+poweroff_confirm_img = lv.btn(poweroff_screen)
+poweroff_confirm_img.set_pos(int(32),int(46))
+poweroff_confirm_img.set_size(176,46)
+poweroff_confirm_img.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+screen_btn_1_label = lv.label(poweroff_confirm_img)
+screen_btn_1_label.set_text("关机")
+poweroff_confirm_img.set_style_pad_all(0, lv.STATE.DEFAULT)
+screen_btn_1_label.align(lv.ALIGN.CENTER,0,0)
+# create style style_screen_btn_1_main_main_default
+style_screen_btn_1_main_main_default = lv.style_t()
+style_screen_btn_1_main_main_default.init()
+style_screen_btn_1_main_main_default.set_radius(20)
+style_screen_btn_1_main_main_default.set_bg_color(lv.color_make(249,47,109))
+style_screen_btn_1_main_main_default.set_bg_grad_color(lv.color_make(249,47,109))
+style_screen_btn_1_main_main_default.set_bg_grad_dir(lv.GRAD_DIR.NONE)
+style_screen_btn_1_main_main_default.set_bg_opa(255)
+style_screen_btn_1_main_main_default.set_border_color(lv.color_make(249,47,109))
+style_screen_btn_1_main_main_default.set_border_width(0)
+style_screen_btn_1_main_main_default.set_border_opa(255)
+style_screen_btn_1_main_main_default.set_text_color(lv.color_make(0xff,0xff,0xff))
+style_screen_btn_1_main_main_default.set_text_font(lv.K01_font_16_ALL)
+style_screen_btn_1_main_main_default.set_text_align(lv.TEXT_ALIGN.CENTER)
+
+# add style for screen_btn_1
+poweroff_confirm_img.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
+
+
+# poweroff_confirm_img = lv.img(poweroff_screen)
+# poweroff_confirm_img.set_size(176, 46)
+# poweroff_confirm_img.set_pos(32, 160)
+# poweroff_confirm_img.set_src("U:/static/off_icon.png")
+# poweroff_confirm_img.add_flag(lv.obj.FLAG.CLICKABLE)
+# poweroff_confirm_img.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+# poweroff_confirm_label = lv.label(poweroff_confirm_img)
+# poweroff_confirm_label.set_text("关机")
+# poweroff_confirm_label.align(lv.ALIGN.CENTER, 0, 5)
+# poweroff_confirm_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
+
+# poweroff_return = lv.img(poweroff_screen)
+# poweroff_return.set_size(176, 46)
+# poweroff_return.set_pos(32, 230)
+# poweroff_return.set_src("U:/static/cancel_icon.png")
+# poweroff_return.add_flag(lv.obj.FLAG.CLICKABLE)
+# poweroff_return.add_style(style_img, lv.PART.MAIN | lv.STATE.DEFAULT)
+# poweroff_return_label = lv.label(poweroff_return)
+# poweroff_return_label.set_text("返回")
+# poweroff_return_label.align(lv.ALIGN.CENTER, 0, 5)
+# poweroff_return_label.add_style(style_font_youyuan_20, lv.PART.MAIN | lv.STATE.DEFAULT)
+# poweroff_return.set_ext_click_area(20)
+
+poweroff_return = lv.btn(poweroff_screen)
+poweroff_return.set_pos(int(32),int(230))
+poweroff_return.set_size(176,46)
+poweroff_return.set_scrollbar_mode(lv.SCROLLBAR_MODE.OFF)
+screen_btn_1_label = lv.label(poweroff_return)
+screen_btn_1_label.set_text("返回")
+poweroff_return.set_style_pad_all(0, lv.STATE.DEFAULT)
+screen_btn_1_label.align(lv.ALIGN.CENTER,0,0)
+# create style style_screen_btn_1_main_main_default
+style_screen_btn_1_main_main_default = lv.style_t()
+style_screen_btn_1_main_main_default.init()
+style_screen_btn_1_main_main_default.set_radius(20)
+style_screen_btn_1_main_main_default.set_bg_color(lv.color_make(7,222,169))
+style_screen_btn_1_main_main_default.set_bg_grad_color(lv.color_make(7,222,169))
+style_screen_btn_1_main_main_default.set_bg_grad_dir(lv.GRAD_DIR.NONE)
+style_screen_btn_1_main_main_default.set_bg_opa(255)
+style_screen_btn_1_main_main_default.set_border_color(lv.color_make(7,222,169))
+style_screen_btn_1_main_main_default.set_border_width(0)
+style_screen_btn_1_main_main_default.set_border_opa(255)
+style_screen_btn_1_main_main_default.set_text_color(lv.color_make(0xff,0xff,0xff))
+style_screen_btn_1_main_main_default.set_text_font(lv.K01_font_16_ALL)
+style_screen_btn_1_main_main_default.set_text_align(lv.TEXT_ALIGN.CENTER)
+
+# add style for screen_btn_1
+poweroff_return.add_style(style_screen_btn_1_main_main_default, lv.PART.MAIN|lv.STATE.DEFAULT)
 
 
 
diff --git a/2.sdk-ZY/project/W9/usr/static/SOS_PLAY.mp3 b/2.sdk-ZY/project/W9/usr/static/SOS_PLAY.mp3
deleted file mode 100644 (file)
index f2588cd..0000000
Binary files a/2.sdk-ZY/project/W9/usr/static/SOS_PLAY.mp3 and /dev/null differ
diff --git a/2.sdk-ZY/project/W9/usr/static/cancel_icon.png b/2.sdk-ZY/project/W9/usr/static/cancel_icon.png
deleted file mode 100644 (file)
index 905ad0a..0000000
Binary files a/2.sdk-ZY/project/W9/usr/static/cancel_icon.png and /dev/null differ
index 8188349..ffce60c 100644 (file)
Binary files a/2.sdk-ZY/project/W9/usr/static/low_power.png and b/2.sdk-ZY/project/W9/usr/static/low_power.png differ