コード例 #1
0
        public bool ExcecuteEESGetCar(EESData objEESData)
        {
            bool success      = false;
            int  printCounter = 0;

            if (objQueueControllerService == null)
            {
                objQueueControllerService = new QueueControllerImp();
            }
            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                do
                {
                    success = opcd.WriteTag <bool>(objEESData.machineChannel, objEESData.machineCode, objEESData.command, true);
                    System.Threading.Thread.Sleep(1000);

                    printCounter += 1;
                    if (printCounter > 3)
                    {
                        //checking transaction deleted or not
                        objQueueControllerService.CancelIfRequested(objEESData.queueId);
                        Logger.WriteLogger(GlobalValues.PARKING_LOG, "Queue Id:" + objEESData.queueId + ":--Failed to excecute get car for EES" + objEESData.machineCode);
                        printCounter = 0;
                    }
                } while (!IsDoneExcecuteEESGetCar(objEESData));
            }
            return(success);
        }
コード例 #2
0
        public bool IsEESReadyForChangeMode(EESData objEESData)
        {
            bool isEESReady = false;

            objEESDaoService = new EESDaoImp();

            isEESReady = CheckEESHealthy(objEESData);

            isEESReady = isEESReady && !objEESDaoService.IsEESBlockedInDBForParking(objEESData.machineCode);
            isEESReady = isEESReady && !objEESDaoService.IsEESBlockedInDBForPMS(objEESData.machineCode);
            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                isEESReady = isEESReady && opcd.ReadTag <bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_L2_Change_Mode_OK);


                //    isEESReady = isEESReady && opcd.ReadTag<bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_L2_Change_Mode_OK);
                //    //isEESReady = isEESReady && !opcd.ReadTag<bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_Inner_Door_Close_Con);
                //    //isEESReady = isEESReady && !opcd.ReadTag<bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_Inner_Door_Open_Con);
                //    //isEESReady = isEESReady && !opcd.ReadTag<bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_Outer_Door_Close_Con);
                //    //isEESReady = isEESReady && !opcd.ReadTag<bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_Outer_Door_Open_Con);
                //    //isEESReady = isEESReady && !opcd.ReadTag<bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_LOCKED_BY_PS);
                //    //isEESReady = isEESReady && !opcd.ReadTag<bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_LOCKED_BY_REM);
            }

            return(isEESReady);
        }
コード例 #3
0
        public bool AsynchReadSettings()
        {
            // add a periodic data callback group and add one item to the group
            OPCDA.NET.RefreshEventHandler dch = new OPCDA.NET.RefreshEventHandler(AsynchReadListenerForPS);
            uGrp = new OPCDA.NET.RefreshGroup(OpcConnection.GetOPCServerConnection(), DAUpdateRate, dch);

            int rtc = 0;

            PSDaoService        objPSDaoService = new PSDaoImp();
            List <Model.PSData> psList          = objPSDaoService.GetPSList();


            try
            {
                foreach (Model.PSData objPSData in psList)
                {
                    rtc = uGrp.Add(objPSData.machineChannel + "." + objPSData.machineCode + "." + OpcTags.PS_Shuttle_Aisle_Position_for_L2);
                    rtc = uGrp.Add(objPSData.machineChannel + "." + objPSData.machineCode + "." + OpcTags.PS_L2_Max_Window_Limit);
                    rtc = uGrp.Add(objPSData.machineChannel + "." + objPSData.machineCode + "." + OpcTags.PS_L2_Min_Window_Limit);
                }
            }
            catch (Exception errMsg)
            {
                rtc = 0;
                Console.WriteLine(errMsg.Message);
            }
            finally
            {
            }

            return(rtc == 0 ? false : true);
        }
コード例 #4
0
        public bool UpdateMachineValues()
        {
            objVLCDaoService = new VLCDaoImp();
            List <VLCData> vlcList;
            bool           result;
            int            dataValue;
            bool           dataValueInBool;



            try
            {
                vlcList = objVLCDaoService.GetVLCList();
                using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
                {
                    foreach (VLCData objVLCData in vlcList)
                    {
                        if (opcd.IsMachineHealthy(objVLCData.machineChannel + "." + objVLCData.machineCode + "." + OpcTags.VLC_Auto_Ready) == true)
                        {
                            dataValueInBool = false;
                            dataValueInBool = opcd.ReadTag <bool>(objVLCData.machineChannel, objVLCData.machineCode, OpcTags.VLC_Auto_Ready);
                            UpdateVLCBoolData(objVLCData.machineCode, OpcTags.VLC_Auto_Ready, dataValueInBool);
                        }
                    }
                }
                result = true;
            }
            catch (Exception errMsg)
            {
                result = false;
                Console.WriteLine(errMsg.Message);
            }
            return(result);
        }
コード例 #5
0
        public bool AsynchReadSettings()
        {
            // add a periodic data callback group and add one item to the group
            OPCDA.NET.RefreshEventHandler dch = new OPCDA.NET.RefreshEventHandler(AsynchReadListenerForVLC);
            uGrp = new OPCDA.NET.RefreshGroup(OpcConnection.GetOPCServerConnection(), DAUpdateRate, dch);

            int rtc = 0;

            VLCDaoService  objVLCDaoService = new VLCDaoImp();
            List <VLCData> vlcList          = objVLCDaoService.GetVLCList();


            try
            {
                foreach (VLCData objVLCData in vlcList)
                {
                    rtc = uGrp.Add(objVLCData.machineChannel + "." + objVLCData.machineCode + "." + OpcTags.VLC_Auto_Ready);
                }
            }
            catch (Exception errMsg)
            {
                rtc = 0;
                Console.WriteLine(errMsg.Message);
            }
            finally
            {
            }

            return(rtc == 0 ? false : true);
        }
コード例 #6
0
        public bool IsCameraHealthy(string command)
        {
            bool result = false;

            //qualityBits machineQuality = qualityBits.bad;

            try
            {
                camOpcServer = OpcConnection.GetOPCServerConnection();
                ItemProperties[] item = null;


                //get value of command.
                item = objOpcServer.GetProperties(new string[1] {
                    command
                }, true, new int[] { 3 });

                Property property = item[0].Properties[0];
                result = ((OPCDA.OPCQuality)property.Value).QualityField == OPCDA.qualityBits.good;
            }
            catch (Exception errMsg)
            {
                result = false;
                Console.WriteLine(errMsg.Message);
            }

            finally
            {
                //Console.WriteLine(command);
            }


            return(result);
        }
コード例 #7
0
        public bool PVLPut(Model.PVLData objPVLData)
        {
            bool isPVLHealthy = false;
            bool success      = false;

            //do
            //{
            try
            {
                isPVLHealthy = CheckPVLHealthy(objPVLData);

                if (!isPVLHealthy)
                {
                    return(false);
                }

                using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
                {
                    success = opcd.WriteTag <bool>(objPVLData.machineChannel, objPVLData.machineCode, objPVLData.command, true);
                    Thread.Sleep(500);
                    success = opcd.WriteTag <bool>(objPVLData.machineChannel, objPVLData.machineCode, objPVLData.command, false);
                }
            }
            catch (Exception ex)
            {
                Console.WriteLine(ex);
                success = false;
            }


            // } while (!success);
            return(success);
        }
コード例 #8
0
        public bool IsPalletOnPVL(Model.PVLData objPVLData, out bool isHealthy)
        {
            Logger.WriteLogger(GlobalValues.PMS_LOG, "Entered IsPalletOnPVL : PVL=" + objPVLData.machineCode);
            bool isPalletPresent = true;

            isHealthy = false;
            int    checkCount = 0;
            string pvlDeck    = GetDeckCodeOfPVL(objPVLData.machineCode);

            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                do
                {
                    //string pvlDeck = objPVLData.machineCode.Replace("Drive", "Deck");
                    isHealthy = opcd.IsMachineHealthy(objPVLData.machineChannel + "." + objPVLData.machineCode + "." + OpcTags.PVL_Auto_Ready);
                    if (isHealthy)
                    {
                        isPalletPresent = opcd.ReadTag <bool>(objPVLData.machineChannel, pvlDeck, OpcTags.PVL_West_Pallet_Present);
                        isPalletPresent = isPalletPresent || opcd.ReadTag <bool>(objPVLData.machineChannel, pvlDeck, OpcTags.PVL_East_Pallet_Present);
                    }
                    checkCount++;
                    Thread.Sleep(100);
                } while (!isPalletPresent && checkCount < 5);
            }
            Logger.WriteLogger(GlobalValues.PMS_LOG, "Exitting IsPalletOnPVL : PVL=" + objPVLData.machineCode
                               + ", isPalletPresent= " + isPalletPresent + ", isHealthy= " + isHealthy);
            return(isPalletPresent);
        }
コード例 #9
0
        public bool testAsynchReadSettings()
        {
            OPCDA.NET.RefreshEventHandler dch = new OPCDA.NET.RefreshEventHandler(AsynchReadListenerForCM);
            OpcServer opcServer = OpcConnection.GetOPCServerConnection();

            uGrp = new OPCDA.NET.RefreshGroup(opcServer, DAUpdateRate, dch);
            return(true);
        }
コード例 #10
0
        public int GetEESMode(EESData objEESData)
        {
            Int32 eesMode;

            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                eesMode = opcd.ReadTag <Int32>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_Mode);
            }
            return(eesMode);
        }
コード例 #11
0
        public int VLCAtFloor(VLCData objVLCData)
        {
            int vlcFloor = 0;

            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                vlcFloor = opcd.ReadTag <Int32>(objVLCData.machineChannel, objVLCData.machineCode, OpcTags.VLC_At_Floor);
            }
            return(vlcFloor);
        }
コード例 #12
0
        public bool checkCarReadyAtEntry(EESData objEESData)
        {
            bool carReadyAtEntry = false;

            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                carReadyAtEntry = opcd.ReadTag <bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_Car_Ready_At_Entry);
            }
            return(carReadyAtEntry);
        }
コード例 #13
0
        public bool ExcecutePaymentDone(EESData objEESData)
        {
            bool success = false;

            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                success = opcd.WriteTag <bool>(objEESData.machineChannel, objEESData.machineCode, objEESData.command, true);
            }
            return(success);
        }
コード例 #14
0
        public bool IsDoneExcecuteEESGetCar(EESData objEESData)
        {
            bool isDone = false;

            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                isDone = opcd.ReadTag <bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_InDoor_NotClosed_LS);
            }
            return(isDone);
        }
コード例 #15
0
        public bool GetVehicleDetectorStatus(Model.EESData objEESData)
        {
            bool status = false;

            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                status = opcd.ReadTag <bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_Vehicle_Detector);
            }

            return(status);
        }
コード例 #16
0
        public bool PSMove(Model.PSData objPSData)
        {
            //Logger.WriteLogger(GlobalValues.PMS_LOG, "Entering PSMove: " + objPSData.machineCode+" >> dest_aisle: "+objPSData.destAisle);
            bool isPSHealthy = false;
            bool success     = false;
            bool isPathClear = false;


            //do
            //{
            try
            {
                isPSHealthy = CheckPSHealthy(objPSData);

                if (!isPSHealthy)
                {
                    return(false);
                }

                using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
                {
                    objPSData.dynamicHome = opcd.ReadTag <Int32>(objPSData.machineChannel, objPSData.machineCode, OpcTags.PS_Shuttle_Aisle_Position_for_L2);
                    if (objPSData.dynamicHome != objPSData.destAisle)
                    {
                        isPathClear = ClearPathForPS(objPSData);
                        if (isPathClear)
                        {
                            opcd.WriteTag <int>(objPSData.machineChannel, objPSData.machineCode, OpcTags.PS_L2_Destination_Aisle, objPSData.destAisle);

                            success = opcd.WriteTag <bool>(objPSData.machineChannel, objPSData.machineCode, objPSData.command, true);
                        }
                    }
                    else
                    {
                        success = true;
                    }
                }
            }
            catch (Exception ex)
            {
                Logger.WriteLogger(GlobalValues.PMS_LOG, "Error in PSMove: " + objPSData.machineCode
                                   + " >> dest_aisle: " + objPSData.destAisle + "; error: " + ex.Message);
                success = false;
            }
            finally
            {
                //Logger.WriteLogger(GlobalValues.PMS_LOG, "Exitting PSMove: " + objPSData.machineCode + " >> dest_aisle: " + objPSData.destAisle);
            }


            //} while (!success);

            return(success);
        }
コード例 #17
0
        public bool GetCarAtEESStatus(string eesChannel, string eesCode)
        {
            bool dataValueInBool = false;

            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                dataValueInBool = opcd.ReadTag <bool>(eesChannel, eesCode, OpcTags.EES_Car_At_EES);
                dataValueInBool = dataValueInBool || opcd.ReadTag <bool>(eesChannel, eesCode, OpcTags.EES_OutDoor_NotClosed_LS);
            }
            return(dataValueInBool);
        }
コード例 #18
0
        public bool IsEESReadyForPS(EESData objEESData)
        {
            bool isReady = false;

            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                if (opcd.IsMachineHealthy(objEESData.machineChannel + "." + objEESData.machineCode + "." + OpcTags.EES_Auto_Ready))
                {
                    isReady = opcd.ReadTag <bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_Ready_for_PS_Lock);
                }
            }
            return(isReady);
        }
コード例 #19
0
        public bool IsEESEntryInOPC(EESData objEESData)
        {
            bool isEntry = false;

            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                if (opcd.IsMachineHealthy(objEESData.machineChannel + "." + objEESData.machineCode + "." + OpcTags.EES_Auto_Ready))
                {
                    isEntry = opcd.ReadTag <Int32>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_Mode) == GlobalValues.EESEntry;
                }
            }
            return(isEntry);
        }
コード例 #20
0
        public bool SetHighCarBitForCarWash(VLCData objVLCData, bool bit)
        {
            bool success = false;

            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                if (opcd.IsMachineHealthy(objVLCData.machineChannel + "." + objVLCData.machineCode + "." + OpcTags.WASH_CarWash_HighCar))
                {
                    success = opcd.WriteTag <bool>(objVLCData.machineChannel, objVLCData.machineCode, OpcTags.WASH_CarWash_HighCar, bit);
                }
            }
            return(success);
        }
コード例 #21
0
        public int GetAisleOfPS(Model.PSData objPSData)
        {
            int aisle = 0;

            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                if (opcd.IsMachineHealthy(objPSData.machineChannel + "." + objPSData.machineCode + "." + OpcTags.PS_Shuttle_Aisle_Position_for_L2))
                {
                    aisle = opcd.ReadTag <Int32>(objPSData.machineChannel, objPSData.machineCode, OpcTags.PS_Shuttle_Aisle_Position_for_L2);
                }
            }
            return(aisle);
        }
コード例 #22
0
        public int GetEESState(EESData objEESData)
        {
            int eesState = 0;

            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                if (opcd.IsMachineHealthy(objEESData.machineChannel + "." + objEESData.machineCode + "." + OpcTags.EES_Auto_Ready))
                {
                    eesState = opcd.ReadTag <int>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_State_EES_HMI);
                }
            }
            return(eesState);
        }
コード例 #23
0
        public bool UpdateMachineValues()
        {
            objEESDaoService = new EESDaoImp();
            List <EESData> eesList;
            bool           result;
            int            dataValue;
            bool           dataValueInBool;



            try
            {
                eesList = objEESDaoService.GetEESList();
                using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
                {
                    foreach (EESData objEESData in eesList)
                    {
                        if (opcd.IsMachineHealthy(objEESData.machineChannel + "." + objEESData.machineCode + "." + OpcTags.EES_Auto_Mode) == true)
                        {
                            //dataValueInBool = false;
                            //dataValueInBool = opcd.ReadTag<bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_Auto_Mode);
                            // UpdateEESBoolData(objEESData.machineCode, OpcTags.EES_Auto_Mode, dataValueInBool);

                            dataValueInBool = false;
                            dataValueInBool = opcd.ReadTag <bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_Auto_Ready);
                            UpdateEESBoolData(objEESData.machineCode, OpcTags.EES_Auto_Ready, dataValueInBool);

                            dataValueInBool = false;
                            dataValueInBool = opcd.ReadTag <bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_Car_Ready_At_Entry);
                            UpdateEESBoolData(objEESData.machineCode, OpcTags.EES_Car_Ready_At_Entry, dataValueInBool);

                            dataValueInBool = false;
                            dataValueInBool = opcd.ReadTag <bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_Car_Ready_At_Exit);
                            UpdateEESBoolData(objEESData.machineCode, OpcTags.EES_Car_Ready_At_Exit, dataValueInBool);

                            dataValueInBool = false;
                            dataValueInBool = GetCarAtEESStatus(objEESData.machineChannel, objEESData.machineCode);
                            UpdateEESBoolData(objEESData.machineCode, OpcTags.EES_Car_At_EES, dataValueInBool);
                        }
                    }
                }
                result = true;
            }
            catch (Exception errMsg)
            {
                result = false;
                Console.WriteLine(errMsg.Message);
            }
            return(result);
        }
コード例 #24
0
        public bool IsPalletPresentOnEES(Model.EESData objEESData)
        {
            bool isPresent = false;

            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                if (opcd.IsMachineHealthy(objEESData.machineChannel + "." + objEESData.machineCode + "." + OpcTags.EES_Auto_Ready))
                {
                    isPresent = opcd.ReadTag <bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_Pallet_Present_Prox_NE);
                    isPresent = isPresent || opcd.ReadTag <bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_Pallet_Present_Prox_SW);
                }
            }
            return(isPresent);
        }
コード例 #25
0
        public bool IsPVLReadyForPUTByCM(Model.PVLData objPVLData)
        {
            bool   isReady = false;
            string pvlDeck = GetDeckCodeOfPVL(objPVLData.machineCode);

            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                if (opcd.IsMachineHealthy(objPVLData.machineChannel + "." + objPVLData.machineCode + "." + OpcTags.PVL_Auto_Ready))
                {
                    isReady = !opcd.ReadTag <bool>(objPVLData.machineChannel, pvlDeck, OpcTags.PVL_Deck_Pallet_Present);
                    isReady = isReady && CheckPVLHealthy(objPVLData);
                }
            }
            return(isReady);
        }
コード例 #26
0
        public bool StartCarWash(Modules.Machines.VLC.Model.VLCData objVLCData)
        {
            bool success = false;

            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                if (opcd.IsMachineHealthy(objVLCData.machineChannel + "." + objVLCData.machineCode + "." + OpcTags.WASH_CarWash_Start_Cycle))
                {
                    success = opcd.WriteTag <bool>(objVLCData.machineChannel, objVLCData.machineCode, objVLCData.command, true);
                    Thread.Sleep(2000);
                    success = opcd.WriteTag <bool>(objVLCData.machineChannel, objVLCData.machineCode, objVLCData.command, false);
                }
            }
            return(success);
        }
コード例 #27
0
        public bool UpdateMachineValues()
        {
            objPSDaoService = new PSDaoImp();
            List <Model.PSData> psList;
            bool result;
            int  dataValue;
            bool dataValueInBool;



            try
            {
                psList = objPSDaoService.GetPSList();
                using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
                {
                    foreach (Model.PSData objPSData in psList)
                    {
                        if (opcd.IsMachineHealthy(objPSData.machineChannel + "." + objPSData.machineCode + "." + OpcTags.PS_Auto_Mode) == true)
                        {
                            dataValue = opcd.ReadTag <Int16>(objPSData.machineChannel, objPSData.machineCode, OpcTags.PS_Shuttle_Aisle_Position_for_L2);
                            if (dataValue > 0)
                            {
                                UpdatePSIntData(objPSData.machineCode, OpcTags.PS_Shuttle_Aisle_Position_for_L2, dataValue);
                            }
                            dataValue = opcd.ReadTag <Int16>(objPSData.machineChannel, objPSData.machineCode, OpcTags.PS_L2_Max_Window_Limit);
                            if (dataValue > 0)
                            {
                                UpdatePSIntData(objPSData.machineCode, OpcTags.PS_L2_Max_Window_Limit, dataValue);
                            }
                            dataValue = opcd.ReadTag <Int16>(objPSData.machineChannel, objPSData.machineCode, OpcTags.PS_L2_Min_Window_Limit);
                            if (dataValue > 0)
                            {
                                UpdatePSIntData(objPSData.machineCode, OpcTags.PS_L2_Min_Window_Limit, dataValue);
                            }
                        }
                    }
                }
                result = true;
            }
            catch (Exception errMsg)
            {
                result = false;
                Console.WriteLine(errMsg.Message);
            }
            return(result);
        }
コード例 #28
0
        public bool CheckPSHealthy(Model.PSData objPSData)
        {
            bool isHealthy = false;

            objPSDaoService = new PSDaoImp();

            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                if (opcd.IsMachineHealthy(objPSData.machineChannel + "." + objPSData.machineCode + "." + OpcTags.PS_Shuttle_Aisle_Position_for_L2))
                {
                    isHealthy = opcd.ReadTag <bool>(objPSData.machineChannel, objPSData.machineCode, OpcTags.PS_L2_Auto_Ready_Bit);
                    isHealthy = isHealthy && !objPSDaoService.IsPSDisabled(objPSData.machineCode);
                    isHealthy = isHealthy && !objPSDaoService.IsPSSwitchOff(objPSData.machineCode);
                }
            }
            return(isHealthy);
        }
コード例 #29
0
        public bool GetMidHeightSensorStatus(EESData objEESData)
        {
            bool midSensor = false;

            try
            {
                using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
                {
                    //for low car is true, for high car its false.
                    midSensor = opcd.ReadTag <bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_Mid_Height_Sensor_Blocked);
                }
            }
            finally
            {
            }

            return(midSensor);
        }
コード例 #30
0
        public bool CheckEESHealthy(EESData objEESData)
        {
            bool isHealthy = false;

            objEESDaoService = new EESDaoImp();

            using (OpcOperationsService opcd = new OpcOperationsImp(OpcConnection.GetOPCServerConnection()))
            {
                if (opcd.IsMachineHealthy(objEESData.machineChannel + "." + objEESData.machineCode + "." + OpcTags.EES_Auto_Ready))
                {
                    isHealthy = opcd.ReadTag <bool>(objEESData.machineChannel, objEESData.machineCode, OpcTags.EES_Auto_Ready);

                    isHealthy = isHealthy && !objEESDaoService.IsEESDisabled(objEESData.machineCode);
                    // isHealthy = isHealthy && !objEESDaoService.IsEESSwitchOff(objEESData.machineCode);
                }
            }
            return(isHealthy);
        }