add - 添加风扇报警状态 输送展示界面添加风机 替换

dep_deliver
wangsr 1 year ago
parent 7234c047c8
commit 77b6f47c0a

@ -60,6 +60,7 @@ namespace Mesnac.Action.ChemicalWeighing.LjDeliver
LjSwitchEntity LjSwitchE = new LjSwitchEntity();
MCLabelEntity LabelE = new MCLabelEntity();
ControlCabinetEntity CabinetE = new ControlCabinetEntity();
FanEntity FanE = new FanEntity();
/// <summary>
/// 报警滚动条
@ -106,6 +107,7 @@ namespace Mesnac.Action.ChemicalWeighing.LjDeliver
ControlsHelper.ControlImport<LjSwith>(LjSwitchE, Controls);
ControlsHelper.ControlImport<MCLabel>(LabelE, Controls);
ControlsHelper.ControlImport<ControlCabinet>(CabinetE, Controls);
ControlsHelper.ControlImport<Fan>(FanE, Controls);
this.AlarmMoveText.Font = new Font("宋体", 15f, FontStyle.Regular, GraphicsUnit.Point, 134);
this.AlarmMoveText.ForeColor = Color.White;
@ -412,12 +414,14 @@ namespace Mesnac.Action.ChemicalWeighing.LjDeliver
PlcTemp.DM2DSM01_Alarm = DB91.DM2DSM01.Alarm;
PlcTemp.DM3DSM01_Alarm = DB91.DM3DSM01.Alarm;
PlcTemp.DM1GDP01_Set = DB91.DM1GDP01.Running;
PlcTemp.DM1ASIG01_Set = DB91.DM1ASIG01.Running;
PlcTemp.DM1BSIG01_Set = DB91.DM1BSIG01.Running;
PlcTemp.DM1CSIG01_Set = DB91.DM1CSIG01.Running;
PlcTemp.DM1DSIG01_Set = DB91.DM1DSIG01.Running;
PlcTemp.DM1ESIG01_Set = DB91.DM1ESIG01.Running;
PlcTemp.DM1GDP01_Alarm = DB91.DM1GDP01.Alarm;
PlcTemp.DM1ASIG01_Alarm = DB91.DM1ASIG01.Alarm;
PlcTemp.DM1BSIG01_Alarm = DB91.DM1BSIG01.Alarm;
PlcTemp.DM1CSIG01_Alarm = DB91.DM1CSIG01.Alarm;
@ -620,25 +624,16 @@ namespace Mesnac.Action.ChemicalWeighing.LjDeliver
private void DB91SetData()
{
ControlsHelper.SetSwitchLight(SwitchlightE.DM1DSM01, PlcTemp.DM1DSM01_Set, PlcTemp.DM1DSM01_Alarm);
ControlsHelper.SetSwitchLight(SwitchlightE.DM2DSM01, PlcTemp.DM2DSM01_Set, PlcTemp.DM2DSM01_Alarm);
ControlsHelper.SetSwitchLight(SwitchlightE.DM3DSM01, PlcTemp.DM3DSM01_Set, PlcTemp.DM3DSM01_Alarm);
ControlsHelper.SetControlCabinet(CabinetE.DM1ASIG011, PlcTemp.DM1ASIG01_Set, PlcTemp.DM1ASIG01_Alarm);
ControlsHelper.SetControlCabinet(CabinetE.DM1ASIG012, PlcTemp.DM1ASIG01_Set, PlcTemp.DM1ASIG01_Alarm);
ControlsHelper.SetControlCabinet(CabinetE.DM1ASIG013, PlcTemp.DM1ASIG01_Set, PlcTemp.DM1ASIG01_Alarm);
ControlsHelper.SetControlCabinet(CabinetE.DM1ASIG014, PlcTemp.DM1ASIG01_Set, PlcTemp.DM1ASIG01_Alarm);
ControlsHelper.SetControlCabinet(CabinetE.DM1BSIG011, PlcTemp.DM1BSIG01_Set, PlcTemp.DM1BSIG01_Alarm);
ControlsHelper.SetControlCabinet(CabinetE.DM1BSIG012, PlcTemp.DM1BSIG01_Set, PlcTemp.DM1BSIG01_Alarm);
ControlsHelper.SetControlCabinet(CabinetE.DM1CSIG011, PlcTemp.DM1CSIG01_Set, PlcTemp.DM1CSIG01_Alarm);
ControlsHelper.SetControlCabinet(CabinetE.DM1CSIG012, PlcTemp.DM1CSIG01_Set, PlcTemp.DM1CSIG01_Alarm);
ControlsHelper.SetControlCabinet(CabinetE.DM1CSIG013, PlcTemp.DM1CSIG01_Set, PlcTemp.DM1CSIG01_Alarm);
ControlsHelper.SetControlCabinet(CabinetE.DM1CSIG014, PlcTemp.DM1CSIG01_Set, PlcTemp.DM1CSIG01_Alarm);
ControlsHelper.SetControlCabinet(CabinetE.DM1DSIG011, PlcTemp.DM1DSIG01_Set, PlcTemp.DM1DSIG01_Alarm);
ControlsHelper.SetControlCabinet(CabinetE.DM1DSIG012, PlcTemp.DM1DSIG01_Set, PlcTemp.DM1DSIG01_Alarm);
ControlsHelper.SetControlCabinet(CabinetE.DM1DSIG013, PlcTemp.DM1DSIG01_Set, PlcTemp.DM1DSIG01_Alarm);
ControlsHelper.SetControlCabinet(CabinetE.DM1DSIG014, PlcTemp.DM1DSIG01_Set, PlcTemp.DM1DSIG01_Alarm);
ControlsHelper.SetControlCabinet(CabinetE.DM1ESIG01, PlcTemp.DM1ESIG01_Set, PlcTemp.DM1ESIG01_Alarm);
ControlsHelper.SetFan(FanE.DM1DSM01, PlcTemp.DM1DSM01_Set, PlcTemp.DM1DSM01_Alarm);
ControlsHelper.SetFan(FanE.DM2DSM01, PlcTemp.DM2DSM01_Set, PlcTemp.DM2DSM01_Alarm);
ControlsHelper.SetFan(FanE.DM3DSM01, PlcTemp.DM3DSM01_Set, PlcTemp.DM3DSM01_Alarm);
ControlsHelper.SetFan(FanE.DM1ASIG01, PlcTemp.DM1ASIG01_Set, PlcTemp.DM1ASIG01_Alarm);
ControlsHelper.SetFan(FanE.DM1BSIG01, PlcTemp.DM1BSIG01_Set, PlcTemp.DM1BSIG01_Alarm);
ControlsHelper.SetFan(FanE.DM1CSIG01, PlcTemp.DM1CSIG01_Set, PlcTemp.DM1CSIG01_Alarm);
ControlsHelper.SetFan(FanE.DM1DSIG01, PlcTemp.DM1DSIG01_Set, PlcTemp.DM1DSIG01_Alarm);
ControlsHelper.SetFan(FanE.DM1ESIG01, PlcTemp.DM1ESIG01_Set, PlcTemp.DM1ESIG01_Alarm);
ControlsHelper.SetFan(FanE.DM1GDP01, PlcTemp.DM1GDP01_Set, PlcTemp.DM1GDP01_Alarm);
}

@ -187,10 +187,6 @@ namespace Mesnac.Action.ChemicalWeighing.LjDeliver.Entity
public SwitchLight Atank5 { get; set; }
public SwitchLight Atank6 { get; set; }
public SwitchLight DM1DSM01 { get; set; }
public SwitchLight DM2DSM01 { get; set; }
public SwitchLight DM3DSM01 { get; set; }
public SwitchLight HighLevel1 { get; set; }
public SwitchLight HighLevel2 { get; set; }
public SwitchLight HighLevel3 { get; set; }
@ -229,20 +225,36 @@ namespace Mesnac.Action.ChemicalWeighing.LjDeliver.Entity
internal class ControlCabinetEntity
{
public ControlCabinet DM1ASIG011 { get; set; }
public ControlCabinet DM1ASIG012 { get; set; }
public ControlCabinet DM1ASIG013 { get; set; }
public ControlCabinet DM1ASIG014 { get; set; }
public ControlCabinet DM1BSIG011 { get; set; }
public ControlCabinet DM1BSIG012 { get; set; }
public ControlCabinet DM1CSIG011 { get; set; }
public ControlCabinet DM1CSIG012 { get; set; }
public ControlCabinet DM1CSIG013 { get; set; }
public ControlCabinet DM1CSIG014 { get; set; }
public ControlCabinet DM1DSIG011 { get; set; }
public ControlCabinet DM1DSIG012 { get; set; }
public ControlCabinet DM1DSIG013 { get; set; }
public ControlCabinet DM1DSIG014 { get; set; }
public ControlCabinet DM1ESIG01 { get; set; }
public ControlCabinet Cabinet1 { get; set; }
public ControlCabinet Cabinet2 { get; set; }
public ControlCabinet Cabinet3 { get; set; }
public ControlCabinet Cabinet4 { get; set; }
public ControlCabinet Cabinet5 { get; set; }
public ControlCabinet Cabinet6 { get; set; }
public ControlCabinet Cabinet7 { get; set; }
public ControlCabinet Cabinet8 { get; set; }
public ControlCabinet Cabinet9 { get; set; }
public ControlCabinet Cabinet10 { get; set; }
public ControlCabinet Cabinet11{ get; set; }
public ControlCabinet Cabinet12 { get; set; }
public ControlCabinet Cabinet13 { get; set; }
public ControlCabinet Cabinet14 { get; set; }
public ControlCabinet Cabinet15 { get; set; }
}
internal class FanEntity
{
public Fan DM1DSM01 { get; set; }
public Fan DM2DSM01 { get; set; }
public Fan DM3DSM01 { get; set; }
public Fan DM1GDP01 { get; set; }
public Fan DM1ASIG01 { get; set; }
public Fan DM1BSIG01 { get; set; }
public Fan DM1CSIG01 { get; set; }
public Fan DM1DSIG01 { get; set; }
public Fan DM1ESIG01 { get; set; }
}
}

@ -352,10 +352,12 @@ namespace Mesnac.Action.ChemicalWeighing.LjDeliver.Entity
public bool DM1CSIG01_Set { get; set; }
public bool DM1DSIG01_Set { get; set; }
public bool DM1ESIG01_Set { get; set; }
public bool DM1GDP01_Set { get; set; }
public bool DM1ASIG01_Alarm { get; set; }
public bool DM1BSIG01_Alarm { get; set; }
public bool DM1CSIG01_Alarm { get; set; }
public bool DM1DSIG01_Alarm { get; set; }
public bool DM1ESIG01_Alarm { get; set; }
public bool DM1GDP01_Alarm { get; set; }
}
}

@ -1666,18 +1666,18 @@ namespace Mesnac.Action.ChemicalWeighing.MainDetailControl
ControlsHelper.SetJzf(JzfE.AS8GET02, PlcReadTemp.AS8GET02_Set);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1ADF01, PlcReadTemp.PM1ADF01_Set, false);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1BDF01, PlcReadTemp.PM1BDF01_Set, false);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1CDF01, PlcReadTemp.PM1CDF01_Set, false);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1DDF01, PlcReadTemp.PM1DDF01_Set, false);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1EDF01, PlcReadTemp.PM1EDF01_Set, false);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1FDF01, PlcReadTemp.PM1FDF01_Set, false);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1GDF01, PlcReadTemp.PM1GDF01_Set, false);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1HDF01, PlcReadTemp.PM1HDF01_Set, false);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1IDF01, PlcReadTemp.PM1IDF01_Set, false);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1JDF01, PlcReadTemp.PM1JDF01_Set, false);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1KDF01, PlcReadTemp.PM1KDF01_Set, false);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1LDF01, PlcReadTemp.PM1LDF01_Set, false);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1ADF01, PlcReadTemp.PM1ADF01_Set);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1BDF01, PlcReadTemp.PM1BDF01_Set);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1CDF01, PlcReadTemp.PM1CDF01_Set);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1DDF01, PlcReadTemp.PM1DDF01_Set);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1EDF01, PlcReadTemp.PM1EDF01_Set);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1FDF01, PlcReadTemp.PM1FDF01_Set);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1GDF01, PlcReadTemp.PM1GDF01_Set);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1HDF01, PlcReadTemp.PM1HDF01_Set);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1IDF01, PlcReadTemp.PM1IDF01_Set);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1JDF01, PlcReadTemp.PM1JDF01_Set);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1KDF01, PlcReadTemp.PM1KDF01_Set);
ControlsHelper.SetControlCabinet(ControlCabinetE.PM1LDF01, PlcReadTemp.PM1LDF01_Set);
ControlsHelper.SetMCLabel(LabelE.DryMode4, DB2107.Dryer[3].Mode, 1);
ControlsHelper.SetMCLabel(LabelE.DryStatus4, DB2107.Dryer[3].Status, 2);

@ -227,6 +227,21 @@ namespace Mesnac.Action.ChemicalWeighing.Util
/// </summary>
/// <param name="obj"></param>
/// <param name="set"></param>
public static void SetFan(Fan obj, bool set, bool alarm)
{
if (alarm == true)
{
obj.Status = Fan.Statuses.zsAlarm;
}
else if (set == true)
{
obj.Status = Fan.Statuses.zsTurnOn;
}
else
{
obj.Status = Fan.Statuses.zsTurnOff;
}
}
public static void SetFan(Fan obj, bool set)
{
if (set == true)
@ -259,6 +274,17 @@ namespace Mesnac.Action.ChemicalWeighing.Util
obj.Status = ControlCabinet.Statuses.TurnOff;
}
}
public static void SetControlCabinet(ControlCabinet obj, bool set)
{
if (set == true)
{
obj.Status = ControlCabinet.Statuses.TurnOn;
}
else
{
obj.Status = ControlCabinet.Statuses.TurnOff;
}
}
/// <summary>
/// 胡工报警灯
@ -327,6 +353,7 @@ namespace Mesnac.Action.ChemicalWeighing.Util
/// <param name="value">零到一的值</param>
public static void SetHslBottle(HslBottle hslBottle, float value)
{
hslBottle.ForeColor = Color.White;
hslBottle.Value = value;
}

@ -72,7 +72,9 @@ namespace Mesnac.Controls.Feeding
public enum Statuses
{
zsTurnOff = 0, zsTurnOn = 1
zsTurnOff = 0,
zsTurnOn = 1,
zsAlarm = 2,
}
Statuses _status;
@ -92,12 +94,13 @@ namespace Mesnac.Controls.Feeding
base.Init();
_imageStream = null;
sImages = new string[ 2 ];
sImages = new string[ 3 ];
//sImages[ 0 ] = "Mesnac.Controls.Feeding.Resources.Fan.Fan00.gif";//zsTurnOn
//sImages[ 1 ] = "Mesnac.Controls.Feeding.Resources.Fan.Fan01.png";//zsTurnOff
//sImages[ 2 ] = "Mesnac.Controls.Feeding.Resources.Fan.Fan02.gif";//zsAlarm
sImages[0] = "Mesnac.Controls.Feeding.Resources.Fan.F2.png";//zsTurnOff
sImages[1] = "Mesnac.Controls.Feeding.Resources.Fan.FD2.gif";//zsTurnOn
sImages[2] = "Mesnac.Controls.Feeding.Resources.Fan.FA2.gif";//zsAlarm
//sImages[2] = "Mesnac.Controls.Feeding.Resources.Fan.Fan02.gif";//zsAlarm
//sImages[ 3 ] = "Mesnac.Controls.Feeding.Resources.Fan.F2.png";//zsTurnOff
//sImages[ 4 ] = "Mesnac.Controls.Feeding.Resources.Fan.FD2.gif";//zsTurnOn
@ -137,11 +140,11 @@ namespace Mesnac.Controls.Feeding
}
}
//if ( (int)value < 1 )
//{
// _status = (Statuses)1;
//}
if ( (int)value > 1 )
if ((int)value < 0)
{
_status = (Statuses)0;
}
if ( (int)value > 2 )
{
_status = (Statuses)1;
}

File diff suppressed because it is too large Load Diff
Loading…
Cancel
Save