zhunk 6 месяцев назад
Родитель
Сommit
95519e319d

+ 11 - 9
Application_CBD/applications/control.c

@@ -1783,6 +1783,9 @@ void ResetInit(void)
                    rt_thread_delay(1000);
                }
            }
+            #if DZ_260519 == 1
+            device_status.clear_status = 2;
+            #endif
            #if LAMP_EN == 0
            //排虫
            if(device_status.handle_bugger==0){
@@ -2419,10 +2422,12 @@ void WorkTask(void)
 {
     static int clt_time = 0; //收集时间差秒数
     static int heat_time = 0;
+    static uint8_t workloop = 0;
     LOG_I("工作状态:%d",device_status.work_status);
     LOG_I("开关机状态:%d",device_status.ds);
     while(device_status.work_status==1&&device_status.temp_status==0&&device_status.bat_status==0&&device_status.rain_status==0&&device_status.ds==1&&device_status.clear_status==0)
     {
+        workloop++;
         device_status.work_done = 0;
         if(clt_time==0)
         {
@@ -2627,16 +2632,13 @@ void WorkTask(void)
                 //震动
                 ctr_shake(ON, device_status.shake_sec);
                 device_status.photo_ws = 1;
-//                //补光&&拍照
-//                LOG_I("拍照!!!");
-//                HMI_WRITE("workSta.g0.txt=\"拍照!\"");
-//                ctr_led(ON);
-//                HK_TakePhoto();
-//                //清扫
-//                device_status.clear_status=1;
-                //清扫失效则使用震动
-                //ctr_shake(ON, 100);
             }
+#if DZ_260519 == 1
+            if(workloop==3){
+                  workloop = 0;
+                  device_status.clear_status = 2;
+            }
+#endif
         }
    }
         if(device_status.bat_status == 1 || device_status.temp_status == 1 || device_status.rain_status==1 || device_status.ds==0)

+ 6 - 1
Application_CBD/applications/control.h

@@ -21,6 +21,7 @@
 
 #define BOOT_ERR         1              //1-新bootloader,0-旧bootloader()2023年9月份之前的设备升级需要设置为0
 #define DZ_250723        0              //触发雨控后隔天再解除
+#define DZ_260519        0              //进入工作后,每小时转一次仓
 ////////////////////////////////////////////////////////////////
 #if LAMP_EN == 1
     #define VERSION_HK          "1.(3ledV9).41(HK)"      //4.0海康-三色光源
@@ -29,8 +30,12 @@
     #define VERSION_HK          "1.66.41(HK)"            //4.0海康-1200W
     #define VERSION_HK_2000W    "1.66.40(2000W)"         //4.0水稻
 #endif
-
+#if DZ_260519 == 0
 #define VERSION_ZP          "1.66.1(ZP)"            //1.0转盘
+#else
+#define VERSION_ZP          "DZ_260519"            //1.0转盘
+#endif
+
 #define VERSION_GK          "1.66.1(GK)"            //1.0高空
 
 #define VERSION_XCT         "1.13.6(HK)"            //吸虫塔-海康

+ 2 - 0
Application_CBD/applications/main.c

@@ -117,12 +117,14 @@ static void idle_hook(void)
     time(&now);
     static struct tm alarm_new;
     alarm_new =*localtime(&now);
+#if DZ_260519 == 0
     if((alarm_new.tm_hour)==8&&(alarm_new.tm_min==00)&&(alarm_new.tm_sec==0))
     {
         if (device_status.version_type==1) {
             device_status.clear_status=2 ;  //2024-03-21 :开机不再转仓
         }
     }
+#endif
     if((alarm_new.tm_hour)==8&&(alarm_new.tm_min==20)&&(alarm_new.tm_sec==0))
     {
         rt_hw_cpu_reset();