diff --git a/Doc/산출물문서/23. SW 점검 결과_PTOP_UBISAM_260616_(IO Check 후 일일 결과진척도 공유).xlsx b/Doc/산출물문서/23. SW 점검 결과_PTOP_UBISAM_260616_(IO Check 후 일일 결과진척도 공유).xlsx index 3b6e1d6..9eb809c 100644 Binary files a/Doc/산출물문서/23. SW 점검 결과_PTOP_UBISAM_260616_(IO Check 후 일일 결과진척도 공유).xlsx and b/Doc/산출물문서/23. SW 점검 결과_PTOP_UBISAM_260616_(IO Check 후 일일 결과진척도 공유).xlsx differ diff --git a/Machines/ILSOS_PrismaticRD_PTOP/Device/PLC/PLCController.Address.cs b/Machines/ILSOS_PrismaticRD_PTOP/Device/PLC/PLCController.Address.cs index a9e53a1..f4f51a8 100644 --- a/Machines/ILSOS_PrismaticRD_PTOP/Device/PLC/PLCController.Address.cs +++ b/Machines/ILSOS_PrismaticRD_PTOP/Device/PLC/PLCController.Address.cs @@ -24,7 +24,9 @@ namespace ILSOS_PrismaticRD_PTOP.Device // 260618: M70509 Recipe 변경 요청 (구 PLC_RMS_USED, RMS 미사용으로 폐기 후 재정의) PLC_RECIPE_CHANGE_REQ = 0x09, - // 0x0A ~ 0x0F + // 0x0A ~ 0x0E + // 260621: M70515 bit15 모드전환 요청 (Recipe/Page 확인 팝업 → Auto→Manual 잠시 전환) + PLC_MODE_CHANGE = 0x0F, PLC_WELD_READY_REQ = 0x10, PLC_WELD_WAIT = 0x11, PLC_WELD_COMPLETE_ACK = 0x12, @@ -41,7 +43,9 @@ namespace ILSOS_PrismaticRD_PTOP.Device PLC_DOOR_INTERLOCK_P = 0x6A, PLC_EMO_STATUS_P = 0x6B, // 0x6D - // 0x6F ~ 0x73 + // 0x6F ~ 0x72 + // 260621: M70615 bit15 모드전환 요청 (양극, 음극 PLC_MODE_CHANGE 0x0F 미러) + PLC_MODE_CHANGE_P = 0x73, PLC_WELD_P_READY_REQ = 0x74, PLC_WELD_P_WAIT = 0x75, PLC_WELD_P_COMP_ACK = 0x76, @@ -60,7 +64,9 @@ namespace ILSOS_PrismaticRD_PTOP.Device PC_PAGE_CHANGE_COMPLETE = 0x08, // 260618: M70009 Recipe 변경 완료 응답 (구 PC_EMPTY01, 미사용 → 재정의) PC_RECIPE_CHANGE_COMPLETE = 0x09, - // 0x0A ~ 0x0F + // 0x0A ~ 0x0E + // 260621: M70015 bit15 모드전환 ACK (PC→PLC, #2 AutoRun 복귀 시 전달) + PC_MODE_CHANGE = 0x0F, PC_WELD_READY_ACK = 0x10, PC_WELD_BUSY = 0x11, PC_WELD_COMPLETE = 0x12, @@ -74,6 +80,8 @@ namespace ILSOS_PrismaticRD_PTOP.Device PC_LIGHT_ALARM_STATUS_P = 0x68, PC_HEAVY_ALARM_STATUS_P = 0x69, + // 260621: M70115 bit15 모드전환 ACK (양극, 음극 PC_MODE_CHANGE 0x0F 미러, #2 복귀 시 전달) + PC_MODE_CHANGE_P = 0x73, PC_WELD_P_READY_REQ = 0x74, PC_WELD_P_BUSY = 0x75, PC_WELD_P_COMP_ACK = 0x76, diff --git a/Machines/ILSOS_PrismaticRD_PTOP/Sequences/SeqAutoRunPTOP.cs b/Machines/ILSOS_PrismaticRD_PTOP/Sequences/SeqAutoRunPTOP.cs index 3b959e2..a0ba7c3 100644 --- a/Machines/ILSOS_PrismaticRD_PTOP/Sequences/SeqAutoRunPTOP.cs +++ b/Machines/ILSOS_PrismaticRD_PTOP/Sequences/SeqAutoRunPTOP.cs @@ -111,6 +111,9 @@ namespace ILSOS_PrismaticRD_PTOP.Sequences private static TimeSpan _WeldingSpanTime; //TeacingRun 시퀀스에서 용접 소요시간 private int _CurrentPageNo; + // 260621: bit15 Resume — 정지 시 상태보존 + 재개 시 핸드셰이크 스킵 (VM·시퀀스 공유, 인스턴스 1개라 static) + public static bool ResumeMode = false; + private short plcPageNo = 0;// [0] 페이지 1 =음극 A [1]페이지 2= 양극 P(C) private List plcPageNoList = new List(); @@ -169,6 +172,7 @@ namespace ILSOS_PrismaticRD_PTOP.Sequences > sb.Final); sb.Flows(sb[SEQ_CHECK_CYCLE_STOP] > sb[SEQ_CHECK_PAGENO]); // 루프백: 매 사이클 Page Change bit(0x08) 대기부터 재확인 + sb.Flows(sb[SEQ_CHECK_INIT_CONDITION] > sb[SEQ_SET_PARAMS_UPLOAD_WELDING_LIST_SEQ]); // 260621: Resume 시 핸드셰이크 스킵 sb.Flows(sb[SEQ_CHECK_INIT_CONDITION] > sb[SEQ_COMPLETE] > sb.Final); sb.OnStopped(OnStopped); sb.OnForceError(OnForceError); @@ -280,6 +284,11 @@ namespace ILSOS_PrismaticRD_PTOP.Sequences // return SEQ_COMPLETE; //} Thread.Sleep(5); + if (ResumeMode) + { + Log.I("[CheckInitCondition] ResumeMode → 페이지 핸드셰이크 스킵, 용접리스트 업로드로 이동"); + return SEQ_SET_PARAMS_UPLOAD_WELDING_LIST_SEQ; + } Log.I($"[CheckInitCondition] 조건 확인 완료 → CheckPageNo 이동"); return SEQ_CHECK_PAGENO; } @@ -825,6 +834,15 @@ namespace ILSOS_PrismaticRD_PTOP.Sequences Log.I($"[CheckCycleStop] 사이클 중지 여부 확인 중"); Status.SetWorkingPosition(eWorkingPosition.CHECKING_CYCLE); + // 260621: Resume 사이클 1회 완료 → 출력 bit15 OFF + ResumeMode 해제 (이후 정상 루프 복귀) + if (ResumeMode) + { + _PLC.WriteBit((int)eBitOutput.PC_MODE_CHANGE, false); + _PLC.WriteBit((int)eBitOutput.PC_MODE_CHANGE_P, false); + ResumeMode = false; + Log.I("[CheckCycleStop] Resume 사이클 완료 → PC_MODE_CHANGE OFF, ResumeMode 해제"); + } + Log.I($"[CheckCycleStop] 사이클 계속 진행 → CheckPageNo 이동"); return SEQ_CHECK_PAGENO; } @@ -1098,8 +1116,12 @@ namespace ILSOS_PrismaticRD_PTOP.Sequences // 260512 워드 _PLC.WriteDWord((int)eWordOutput.PC_ERROR_CODE, 0); - _PLC.WriteDWord((int)eWordOutput.PC_PAGE_NO, 0); - _PLC.WriteDWord((int)eWordOutput.PC_RECIPE_NO, 0); // 260618 레시피 No init + // 260621: Resume 정지면 에코 워드(Page/Recipe No) 보존 — PLC가 정합 확인에 쓰므로 0으로 안 지움 + if (!ResumeMode) + { + _PLC.WriteDWord((int)eWordOutput.PC_PAGE_NO, 0); + _PLC.WriteDWord((int)eWordOutput.PC_RECIPE_NO, 0); // 260618 레시피 No init + } Log.I("[OnSeqActionStop] PLC IO Output Word Init"); diff --git a/Machines/ILSOS_PrismaticRD_PTOP/Views/Main/UCMainAutoRun.xaml b/Machines/ILSOS_PrismaticRD_PTOP/Views/Main/UCMainAutoRun.xaml index 3627e39..f26391f 100644 --- a/Machines/ILSOS_PrismaticRD_PTOP/Views/Main/UCMainAutoRun.xaml +++ b/Machines/ILSOS_PrismaticRD_PTOP/Views/Main/UCMainAutoRun.xaml @@ -18,6 +18,7 @@ + @@ -67,21 +68,27 @@ + - + +