Beispiel #1
0
        private void BtnLightControllerPort_Click(object sender, EventArgs e)
        {
            var pDocument = CDocument.GetDocument;

            do
            {
                FormKeyBoard objKey = new FormKeyBoard(m_objLightControllerParameter.strSerialPortName);
                if (DialogResult.OK != objKey.ShowDialog())
                {
                    break;
                }
                if (4 > objKey.m_strReturnValue.Length)
                {
                    break;
                }
                if (-1 == objKey.m_strReturnValue.IndexOf("COM"))
                {
                    break;
                }

                string strPortNumber = objKey.m_strReturnValue.ToUpper();
                // 조명 컨트롤러 생성 & 초기화
                {
                    for (int iLoopCount = 0; iLoopCount < pDocument.m_objProcessMain.m_objLightController.Length; iLoopCount++)
                    {
                        pDocument.m_objProcessMain.m_objLightController[iLoopCount].HLDeInitialize();
                        HLDevice.Abstract.CDeviceLightControllerAbstract.CInitializeParameter objLightControllerInitializeParameter;
                        // 조명 컨트롤러 파라미터 정보 설정
                        objLightControllerInitializeParameter                     = new HLDevice.Abstract.CDeviceLightControllerAbstract.CInitializeParameter();
                        objLightControllerInitializeParameter.eType               = (HLDevice.Abstract.CDeviceLightControllerAbstract.CInitializeParameter.enumType)m_objLightControllerParameter.eType;
                        objLightControllerInitializeParameter.strSerialPortName   = m_objLightControllerParameter.strSerialPortName = strPortNumber;
                        objLightControllerInitializeParameter.iSerialPortBaudrate = m_objLightControllerParameter.iSerialPortBaudrate;
                        objLightControllerInitializeParameter.iSerialPortDataBits = m_objLightControllerParameter.iSerialPortDataBits;
                        objLightControllerInitializeParameter.eParity             = (HLDevice.Abstract.CDeviceLightControllerAbstract.CInitializeParameter.enumSerialPortParity)m_objLightControllerParameter.eParity;
                        objLightControllerInitializeParameter.eStopBits           = (HLDevice.Abstract.CDeviceLightControllerAbstract.CInitializeParameter.enumSerialPortStopBits)m_objLightControllerParameter.eStopBits;
                        objLightControllerInitializeParameter.strSocketIPAddress  = m_objLightControllerParameter.strSocketIPAddress;
                        objLightControllerInitializeParameter.iSocketPortNumber   = m_objLightControllerParameter.iSocketPortNumber;
                        pDocument.m_objConfig.SaveLightControllerParameter(m_objLightControllerParameter, (CDefine.enumLightController)iLoopCount);

                        // 조명 컨트롤러 객체 초기화
                        pDocument.m_objProcessMain.m_objLightController[iLoopCount].HLInitialize(objLightControllerInitializeParameter);
                    }
                }
            } while(false);
        }
Beispiel #2
0
        //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
        //생성 :
        //추가 :
        //목적 : 이름 입력 받음
        //설명 :
        //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
        private void BtnName_Click(object sender, EventArgs e)
        {
            var pDocument = CDocument.GetDocument;
            // 버튼 로그 추가
            string strLog = string.Format("[{0}] [{1}]", "BtnName_Click", true);

            pDocument.SetUpdateButtonLog(this, strLog);

            FormKeyBoard objKeyboard = new FormKeyBoard();

            if (System.Windows.Forms.DialogResult.OK == objKeyboard.ShowDialog())
            {
                m_objRecipeInformationList[m_iSelectedRow].strRecipeName = objKeyboard.m_strReturnValue;
            }
            // 버튼 로그 추가
            strLog = string.Format("[{0}] [Name : {1}] [{2}]", "BtnName_Click", m_objRecipeInformationList[m_iSelectedRow].strRecipeName, false);
            pDocument.SetUpdateButtonLog(this, strLog);
        }
Beispiel #3
0
        //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
        //생성 :
        //추가 :
        //목적 : 생성 레시피 이름 입력 받음
        //설명 :
        //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
        private void BtnCreateName_Click(object sender, EventArgs e)
        {
            var    pDocument = CDocument.GetDocument;
            Button objButton = sender as Button;
            // 버튼 로그 추가
            string strLog = string.Format("[{0}] [{1}]", "BtnCreateName_Click", true);

            pDocument.SetUpdateButtonLog(this, strLog);

            FormKeyBoard objKeyboard = new FormKeyBoard();

            if (System.Windows.Forms.DialogResult.OK == objKeyboard.ShowDialog())
            {
                objButton.Text = objKeyboard.m_strReturnValue.ToUpper();
            }
            // 버튼 로그 추가
            strLog = string.Format("[{0}] [Create Name : {1}] [{2}]", "BtnCreateName_Click", objButton.Text, false);
            pDocument.SetUpdateButtonLog(this, strLog);
        }