|
|
|
@ -1,7 +1,917 @@
|
|
|
|
|
namespace Mesnac.Action.ChemicalWeighing.LjPressure
|
|
|
|
|
using System;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.Linq;
|
|
|
|
|
using DevExpress.XtraGauges.Core.Model;
|
|
|
|
|
using DevExpress.XtraRichEdit.API.Layout;
|
|
|
|
|
|
|
|
|
|
namespace Mesnac.Action.ChemicalWeighing.LjPressure
|
|
|
|
|
{
|
|
|
|
|
public class PressurePLC
|
|
|
|
|
{
|
|
|
|
|
private static BasePlcHelper GetPlcHelper => BasePlcHelper.Instance;
|
|
|
|
|
|
|
|
|
|
#region 压送秤A气源压力 DBW12 数组Id=1
|
|
|
|
|
|
|
|
|
|
private static void DownDbw12(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.mainPress_V1_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.mainPress_V1_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.mainPress_V1_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw12()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView();
|
|
|
|
|
view.LowLimit = basePlcHelper.mainPress_V1_LowLimit.NowValue.ToFloat();
|
|
|
|
|
view.HighLimit = basePlcHelper.mainPress_V1_HighLimit.NowValue.ToFloat();
|
|
|
|
|
view.Alarm = basePlcHelper.mainPress_V1_LowLimit.NowValue.ToInt();
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
private static void DownDbw26(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.topPres_V1_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.topPres_V1_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.topPres_V1_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw26()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView();
|
|
|
|
|
view.LowLimit = basePlcHelper.topPres_V1_LowLimit.NowValue.ToFloat();
|
|
|
|
|
view.HighLimit = basePlcHelper.topPres_V1_HighLimit.NowValue.ToFloat();
|
|
|
|
|
view.Alarm = basePlcHelper.topPres_V1_Alarm.NowValue.ToInt();
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private static void DownDbw40(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.linePres_V1_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.linePres_V1_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.linePres_V1_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw40()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView();
|
|
|
|
|
view.LowLimit = basePlcHelper.linePres_V1_LowLimit.NowValue.ToFloat();
|
|
|
|
|
view.HighLimit = basePlcHelper.linePres_V1_HighLimit.NowValue.ToFloat();
|
|
|
|
|
view.Alarm = basePlcHelper.linePres_V1_Alarm.NowValue.ToInt();
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private static void DownDbw54(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.mainPress_V2_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.mainPress_V2_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.mainPress_V2_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw54()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView();
|
|
|
|
|
view.LowLimit = basePlcHelper.mainPress_V2_LowLimit.NowValue.ToFloat();
|
|
|
|
|
view.HighLimit = basePlcHelper.mainPress_V2_HighLimit.NowValue.ToFloat();
|
|
|
|
|
view.Alarm = basePlcHelper.mainPress_V2_Alarm.NowValue.ToInt();
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private static void DownDbw68(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.topPres_V2_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.topPres_V2_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.topPres_V2_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw68()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView();
|
|
|
|
|
view.LowLimit = basePlcHelper.topPres_V2_LowLimit.NowValue.ToFloat();
|
|
|
|
|
view.HighLimit = basePlcHelper.topPres_V2_HighLimit.NowValue.ToFloat();
|
|
|
|
|
view.Alarm = basePlcHelper.topPres_V2_Alarm.NowValue.ToInt();
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private static void DownDbw82(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.linePres_V2_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.linePres_V2_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.linePres_V2_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw82()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView();
|
|
|
|
|
view.LowLimit = basePlcHelper.linePres_V2_LowLimit.NowValue.ToFloat();
|
|
|
|
|
view.HighLimit = basePlcHelper.linePres_V2_HighLimit.NowValue.ToFloat();
|
|
|
|
|
view.Alarm = basePlcHelper.linePres_V2_Alarm.NowValue.ToInt();
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static void DownDbw96(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.mainPress_V3_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.mainPress_V3_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.mainPress_V3_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw96()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView();
|
|
|
|
|
view.LowLimit = basePlcHelper.mainPress_V3_LowLimit.NowValue.ToFloat();
|
|
|
|
|
view.HighLimit = basePlcHelper.mainPress_V3_HighLimit.NowValue.ToFloat();
|
|
|
|
|
view.Alarm = basePlcHelper.mainPress_V3_Alarm.NowValue.ToInt();
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private static void DownDbw110(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.topPres_V3_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.topPres_V3_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.topPres_V3_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw110()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView();
|
|
|
|
|
view.LowLimit = basePlcHelper.topPres_V3_LowLimit.NowValue.ToFloat();
|
|
|
|
|
view.HighLimit = basePlcHelper.topPres_V3_HighLimit.NowValue.ToFloat();
|
|
|
|
|
view.Alarm = basePlcHelper.topPres_V3_Alarm.NowValue.ToInt();
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static void DownDbw124(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.linePres_V3_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.linePres_V3_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.linePres_V3_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw124()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.linePres_V3_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.linePres_V3_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.linePres_V3_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private static void DownDbw138(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.mainPress_V4_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.mainPress_V4_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.mainPress_V4_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
private static PressureSettingView UpDbw138()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.mainPress_V4_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.mainPress_V4_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.mainPress_V4_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private static void DownDbw152(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.topPres_V4_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.topPres_V4_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.topPres_V4_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw152()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.topPres_V4_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.topPres_V4_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.topPres_V4_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static void DownDbw166(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.linePres_V4_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.linePres_V4_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.linePres_V4_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw166()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.linePres_V4_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.linePres_V4_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.linePres_V4_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private static void DownDbw180(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.mainPress_V5_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.mainPress_V5_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.mainPress_V5_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw180()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.mainPress_V5_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.mainPress_V5_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.mainPress_V5_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private static void DownDbw194(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.topPres_V5_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.topPres_V5_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.topPres_V5_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw194()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.topPres_V5_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.topPres_V5_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.topPres_V5_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static void DownDbw208(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.linePres_V5_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.linePres_V5_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.linePres_V5_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw208()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.linePres_V5_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.linePres_V5_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.linePres_V5_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private static void DownDBW222(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B1_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B1_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.presDay_B1_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw222()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.presDay_B1_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.presDay_B1_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.presDay_B1_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static void DownDBW236(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B2_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B2_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.presDay_B2_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw236()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.presDay_B2_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.presDay_B2_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.presDay_B2_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static void DownDBW250(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B3_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B3_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.presDay_B3_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw250()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.presDay_B3_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.presDay_B3_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.presDay_B3_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static void DownDBW264(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B4_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B4_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.presDay_B4_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw264()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.presDay_B4_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.presDay_B4_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.presDay_B4_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static void DownDBW278(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B5_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B5_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.presDay_B5_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw278()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.presDay_B5_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.presDay_B5_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.presDay_B5_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static void DownDBW292(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B6_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B6_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.presDay_B6_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
private static PressureSettingView UpDbw292()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.presDay_B6_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.presDay_B6_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.presDay_B6_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static void DownDBW306(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B7_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B7_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.presDay_B7_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw306()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.presDay_B7_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.presDay_B7_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.presDay_B7_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static void DownDBW320(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B8_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B8_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.presDay_B8_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw320()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.presDay_B8_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.presDay_B8_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.presDay_B8_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static void DownDBW334(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B9_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B9_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.presDay_B9_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw334()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.presDay_B9_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.presDay_B9_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.presDay_B9_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static void DownDBW348(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B10_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B10_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.presDay_B10_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw348()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.presDay_B10_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.presDay_B10_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.presDay_B10_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static void DownDBW362(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B11_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B11_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.presDay_B11_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw362()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.presDay_B11_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.presDay_B11_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.presDay_B11_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static void DownDBW376(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B12_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.presDay_B12_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.presDay_B12_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw376()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.presDay_B12_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.presDay_B12_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.presDay_B12_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private static void DownDBW390(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.PR2PCP01_B12_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.PR2PCP01_B12_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.PR2PCP01_B12_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw390()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.PR2PCP01_B12_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.PR2PCP01_B12_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.PR2PCP01_B12_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private static void DownDBW404(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.PR2PCP02_B12_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.PR2PCP02_B12_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.PR2PCP02_B12_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw404()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.PR2PCP02_B12_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.PR2PCP02_B12_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.PR2PCP02_B12_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private static void DownDBW418(PressureSettingView view)
|
|
|
|
|
{
|
|
|
|
|
if (view != null)
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.PR2PCP03_B12_LowLimit, view.LowLimit);
|
|
|
|
|
basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.PR2PCP03_B12_HighLimit, view.HighLimit);
|
|
|
|
|
basePlcHelper.PlcWriteByDataKey(basePlcHelper.PR2PCP03_B12_Alarm,
|
|
|
|
|
new object[] { Convert.ToBoolean(view.Alarm) });
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static PressureSettingView UpDbw418()
|
|
|
|
|
{
|
|
|
|
|
var basePlcHelper = GetPlcHelper;
|
|
|
|
|
PressureSettingView view = new PressureSettingView
|
|
|
|
|
{
|
|
|
|
|
LowLimit = basePlcHelper.PR2PCP03_B12_LowLimit.NowValue.ToFloat(),
|
|
|
|
|
HighLimit = basePlcHelper.PR2PCP03_B12_HighLimit.NowValue.ToFloat(),
|
|
|
|
|
Alarm = basePlcHelper.PR2PCP03_B12_Alarm.NowValue.ToInt()
|
|
|
|
|
};
|
|
|
|
|
return view;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 下发到plc
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="ls"></param>
|
|
|
|
|
public static void DownToPlc(List<PressureSettingView> ls)
|
|
|
|
|
{
|
|
|
|
|
foreach (var pressureSettingView in ls)
|
|
|
|
|
{
|
|
|
|
|
int id = pressureSettingView.Id;
|
|
|
|
|
switch (id)
|
|
|
|
|
{
|
|
|
|
|
case 1:
|
|
|
|
|
DownDbw12(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 2:
|
|
|
|
|
DownDbw26(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
case 3:
|
|
|
|
|
DownDbw40(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 4:
|
|
|
|
|
DownDbw54(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 5:
|
|
|
|
|
DownDbw68(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
case 6:
|
|
|
|
|
DownDbw82(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 7:
|
|
|
|
|
DownDbw96(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 8:
|
|
|
|
|
DownDbw110(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 9:
|
|
|
|
|
DownDbw124(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
case 10:
|
|
|
|
|
DownDbw138(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 11:
|
|
|
|
|
DownDbw152(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 12:
|
|
|
|
|
DownDbw166(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 13:
|
|
|
|
|
DownDbw180(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 14:
|
|
|
|
|
DownDbw194(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 15:
|
|
|
|
|
DownDbw208(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 16:
|
|
|
|
|
DownDBW222(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 17:
|
|
|
|
|
DownDBW236(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 18:
|
|
|
|
|
DownDBW250(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
case 19:
|
|
|
|
|
DownDBW264(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 20:
|
|
|
|
|
DownDBW278(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 21:
|
|
|
|
|
DownDBW292(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 22:
|
|
|
|
|
DownDBW306(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 23:
|
|
|
|
|
DownDBW320(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 24:
|
|
|
|
|
DownDBW334(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 25:
|
|
|
|
|
DownDBW348(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 26:
|
|
|
|
|
DownDBW362(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
case 27:
|
|
|
|
|
DownDBW376(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 28:
|
|
|
|
|
DownDBW390(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
case 29:
|
|
|
|
|
DownDBW404(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
case 30:
|
|
|
|
|
DownDBW418(pressureSettingView);
|
|
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 下发到plc
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="ls"></param>
|
|
|
|
|
public static List<PressureSettingView> UpdateFromPlc(int id=0)
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
List<PressureSettingView> ls = new List<PressureSettingView>
|
|
|
|
|
{
|
|
|
|
|
UpDbw12(),
|
|
|
|
|
UpDbw26(),
|
|
|
|
|
UpDbw40(),
|
|
|
|
|
UpDbw54(),
|
|
|
|
|
UpDbw68(),
|
|
|
|
|
UpDbw82(),
|
|
|
|
|
UpDbw96(),
|
|
|
|
|
UpDbw110(),
|
|
|
|
|
UpDbw124(),
|
|
|
|
|
UpDbw138(),
|
|
|
|
|
UpDbw152(),
|
|
|
|
|
UpDbw166(),
|
|
|
|
|
UpDbw180(),
|
|
|
|
|
UpDbw194(),
|
|
|
|
|
UpDbw208(),
|
|
|
|
|
UpDbw222(),
|
|
|
|
|
UpDbw236(),
|
|
|
|
|
UpDbw250(),
|
|
|
|
|
UpDbw264(),
|
|
|
|
|
UpDbw278(),
|
|
|
|
|
UpDbw292(),
|
|
|
|
|
UpDbw306(),
|
|
|
|
|
UpDbw320(),
|
|
|
|
|
UpDbw334(),
|
|
|
|
|
UpDbw348(),
|
|
|
|
|
UpDbw362(),
|
|
|
|
|
UpDbw376(),
|
|
|
|
|
UpDbw390(),
|
|
|
|
|
UpDbw404(),
|
|
|
|
|
UpDbw418()
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
//如果影响效率 单独去一个
|
|
|
|
|
if (id > 0)
|
|
|
|
|
{
|
|
|
|
|
var pressureSettingView = ls.FirstOrDefault(x => x.Id == id);
|
|
|
|
|
return new List<PressureSettingView>() { pressureSettingView };
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return ls;
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|