Kaynağa Gözat

[WallPadMain]
1. 거동 수상자 시나리오 이슈 정리
- 거동 수상자 초기화 BR 추가
- 거동수상자 딜레이 기간동안, 사용 설정으로 인하여 초기화 되는 경우 방지
- 통화중 또는 거동 수상자 녹화 중일 경우, 거동수상자 딜레이가 종료 되어 해당 설정 초기화 되는것을 방지

jglee 2 yıl önce
ebeveyn
işleme
cc40d75c03

+ 28 - 13
WallPadMain/src/main/java/kr/co/icontrols/wallpadmain/MainActivity.java

@@ -10187,7 +10187,7 @@ public class MainActivity extends WpadActivity {
                     //여기서 감지시간을 강제로 늘림
                     if(mSmartKeyRfDoorAPI!=null)
                     {
-                        String ret = mSmartKeyRfDoorAPI.SetSensorConfig((byte) 0x05, (byte)0x10);
+                        String ret = mSmartKeyRfDoorAPI.SetSensorConfig((byte) 0x05, (byte)0x240);
                     }
                 }
             }
@@ -10269,7 +10269,7 @@ public class MainActivity extends WpadActivity {
                         //여기서 감지시간을 강제로 늘림
                         if(mSmartKeyRfDoorAPI!=null)
                         {
-                            String ret = mSmartKeyRfDoorAPI.SetSensorConfig((byte) 0x05, (byte)0x10);
+                            String ret = mSmartKeyRfDoorAPI.SetSensorConfig((byte) 0x05, (byte)0x240);
                         }
                     }
 
@@ -10311,23 +10311,28 @@ public class MainActivity extends WpadActivity {
         public void handleMessage(Message msg) {
             Common.bRecordDelay = false;
 
-            Log.d(TAG, "[recordDelayHandler] RecordDelay Init");
+            Log.d(TAG, "[recordDelayHandler] RecordDelay Init + CallingStatus : " +Common.bWallPadCallingLive);
 
             if (cv_bStrangerVideoRecordUsage) {
                 if (cv_bStrangerUserVideoRecordUsage) {
 
-                    if (mSmartKeyRfDoorAPI != null) mSmartKeyRfDoorAPI.SetLEDmode(Common.SmartRFCamLEDMode.LED_AUTO_ON);
-                    else Log.w(TAG, "[recordDelayHandler] Status LED ON smartKeyRfDoorAPI is null!!");
+                    if(!Common.bWallPadCallingLive)
+                    {
+                        if (mSmartKeyRfDoorAPI != null) mSmartKeyRfDoorAPI.SetLEDmode(Common.SmartRFCamLEDMode.LED_AUTO_ON);
+                        else Log.w(TAG, "[recordDelayHandler] Status LED ON smartKeyRfDoorAPI is null!!");
 
-                    if (mSmartKeyRfDoorAPI != null) mSmartKeyRfDoorAPI.SetCAMERAmode(Common.SmartRFCamStatusMode.STATUS_AUTO_ON);
-                    else Log.w(TAG, "[recordDelayHandler] Status Auto ON smartKeyRfDoorAPI is null!!");
+                        if (mSmartKeyRfDoorAPI != null) mSmartKeyRfDoorAPI.SetCAMERAmode(Common.SmartRFCamStatusMode.STATUS_AUTO_ON);
+                        else Log.w(TAG, "[recordDelayHandler] Status Auto ON smartKeyRfDoorAPI is null!!");
 
-                    //여기서 감지시간을 원래대로 복구
-                    if(mSmartKeyRfDoorAPI!=null)
-                    {
-                        String ret = mSmartKeyRfDoorAPI.SetSensorConfig((byte) 0x05, (byte)0x01);
-                        Log.i(TAG, "[recordDelayHandler SenSorConfig] - Test Setting result = " + ret);
+                        //여기서 감지시간을 원래대로 복구
+                        if(mSmartKeyRfDoorAPI!=null)
+                        {
+                            String ret = mSmartKeyRfDoorAPI.SetSensorConfig((byte) 0x05, (byte)0x01);
+                            Log.i(TAG, "[recordDelayHandler SenSorConfig] - Test Setting result = " + ret);
+                        }
                     }
+
+
                 }
             }
         }
@@ -10346,7 +10351,7 @@ public class MainActivity extends WpadActivity {
             filter.addAction(Common.BR_RECORD_STOP);
             filter.addAction(Common.BR_RECORD_DELAY);
             filter.addAction(Common.BR_RECORD_NOT_USE);
-            //filter.addAction(Common.BR_RECORD_USE);
+            filter.addAction(Common.BR_RECORD_DELAY_INIT);
             mContext.registerReceiver(StrangeRecordBroadcastReceiver, filter);
         } catch (RuntimeException re) {
             LogUtil.errorLogInfo("", TAG, re);
@@ -10381,6 +10386,16 @@ public class MainActivity extends WpadActivity {
             {
                 RecordNotUse(false);
             }
+            else if(intent.getAction().equals(Common.BR_RECORD_DELAY_INIT))
+            {
+                //jglee - 거동수상자 초기화 
+                //시나리오에 따라 딜레이가 있는 경우, 딜레이가 완료 되고 해당 초기화 진행
+                //거동 수상자 설정(사용함)일 경우, 해당 BR 받음
+                Log.d(TAG, "Recrod Delay Init Config, RecordDelay Status :" + Common.bRecordDelay);
+                if(!Common.bRecordDelay)
+                    RecordNotUse(true);
+
+            }
         }
     };
 }

+ 1 - 0
WallPadMain/src/main/java/kr/co/icontrols/wallpadmain/declare/Common.java

@@ -274,6 +274,7 @@ public final class Common {
     public static final String BR_RECORD_STOP               = "StrangeRecordStop"; // jglee. 20220706 거동수상자 Stop(내부사용)
     public static final String BR_RECORD_EXCEPTION          = "StrangeRecordStopException"; // jglee. 20220706 거동수상자 Exception
     public static final String BR_RECORD_NOT_USE            = "StrangeRecordNotUse";        // jglee. 20220728 거동 수상자 사용안함
+    public static final String BR_RECORD_DELAY_INIT         = "StrangeRecordDelayInit";        // jglee. 20220803 거동 수상자 사용 설정 시, 전송 BR
 
     // 거실에너지미터 연동
     public static byte LIVINGEM_CTRL_NORMAL = (byte) 0x00;