Ejemplo n.º 1
0
 private void readTags()
 {
     try
     {
         inDatas.Clear();
         tagDataProvider.GetData(arrTagAdress, out inDatas);
     }
     catch (Exception ex)
     {
     }
 }
Ejemplo n.º 2
0
        /// <summary>
        /// 遍历tag点获取值
        /// </summary>
        public void getTagValues()
        {
            try
            {
                //清空原来的map
                inDatas.Clear();
                //读所有鞍座tag点的值
                tagDataProvider.GetData(arrTagAdress, out inDatas);

                //为每个鞍座的tag点值属性赋值
                foreach (UnitSaddleBase theSaddle in dicSaddles.Values)
                {
                    theSaddle.TagVal_IsLocked             = get_value_x(theSaddle.TagAdd_IsLocked);
                    theSaddle.TagVal_IsOccupied           = get_value_x(theSaddle.TagAdd_IsOccupied);
                    theSaddle.TagVal_LockRequest_FEEDBACK = get_value_x(theSaddle.TagAdd_LockRequest_FEEDBACK);
                    theSaddle.TagVal_LockRequest_SET      = get_value_x(theSaddle.TagAdd_LockRequest_SET);
                }
            }
            catch (Exception er)
            {}
        }
Ejemplo n.º 3
0
        /// <summary>
        /// 遍历tag点获取值
        /// </summary>
        public void getTagValues()
        {
            try
            {
                //清空原来的map
                inDatas.Clear();
                //读所有鞍座tag点的值

                tagDataProvider.GetData(arrTagAdress, out inDatas);

                //为每个鞍座的tag点值属性赋值
                foreach (AreaBase item in dicSaddles.Values)
                {
                    if (item.AreaType == 8)
                    {
                        //  item.AreaDoorSefeValue = get_value_x(item.AreaDoorSefeName);
                        //   item.AreaDoorReserveValue = get_value_x(item.AreaDoorReserveName);
                        //红一区
                        item.SAFE_AREA_1_Value = get_value_x(AreaInfo.ADRESS_SAFE_AREA1);
                        //红二区
                        item.SAFE_AREA_2_Value = get_value_x(AreaInfo.ADRESS_SAFE_AREA2);
                        //红三区
                        item.SAFE_AREA_3_Value = get_value_x(AreaInfo.ADRESS_SAFE_AREA3);
                    }
                    else if (item.AreaType == 7)
                    {
                        item.Safe_door1 = get_value_x(AreaInfo.ADRESS_SAFE_DOOR1);
                        item.Safe_door2 = get_value_x(AreaInfo.ADRESS_SAFE_DOOR2);
                        item.Safe_door3 = get_value_x(AreaInfo.ADRESS_SAFE_DOOR3);
                        item.Safe_door4 = get_value_x(AreaInfo.ADRESS_SAFE_DOOR4);
                        item.Safe_door5 = get_value_x(AreaInfo.ADRESS_SAFE_DOOR5);
                    }
                }
            }
            catch (Exception ex)
            {
            }
        }
Ejemplo n.º 4
0
        /// <summary>
        /// 遍历tag点获取值
        /// </summary>
        public void getTagValues()
        {
            try
            {
                //清空原来的map
                inDatas.Clear();
                //读所有鞍座tag点的值
                tagDataProvider.GetData(arrTagAdress, out inDatas);


                //为每个鞍座的tag点值属性赋值
                foreach (AreaBase item in dicSaddles.Values)
                {
                    if (item.AreaType == 0)
                    {
                        item.AreaDoorSefeValue    = get_value_x(item.AreaDoorSefeName);
                        item.AreaDoorReserveValue = get_value_x(item.AreaDoorReserveName);
                    }
                }
            }
            catch (Exception ex)
            {
            }
        }