读取报表

dep
我叫锄头 12 months ago
parent 2f1fd1f77c
commit bf7bbbab31

@ -283,10 +283,11 @@ namespace Mesnac.Action.ChemicalWeighing.MainDetailControl
ControlsHelper.SetMCLabel(LabelE.LineKind8, dict[8]); ControlsHelper.SetMCLabel(LabelE.LineKind8, dict[8]);
} }
ReadFlag += 1; ReadFlag += 1;
if(ReadFlag >= 10) if(ReadFlag >= 30)
{ {
ReadFlag = 0; ReadFlag = 0;
ReportReadDb.ReadFeededDry(); ReportReadDb.ReadFeededDry();
} }
var reachSingle = RgvPlcUtil.GetRGVAllError(); var reachSingle = RgvPlcUtil.GetRGVAllError();

@ -35,7 +35,7 @@ namespace Mesnac.Action.ChemicalWeighing.Report
/// </summary> /// </summary>
public static void ReadFeededDry() public static void ReadFeededDry()
{ {
LoggingService<ReportReadDb>.Debug("读取加料信息" + DateTime.Now.ToString());
DB2105Helper dB2105Helper = new DB2105Helper(); DB2105Helper dB2105Helper = new DB2105Helper();
List<bool> list = dB2105Helper.FeededDryList(); List<bool> list = dB2105Helper.FeededDryList();
@ -58,7 +58,7 @@ namespace Mesnac.Action.ChemicalWeighing.Report
public static void ReadReport() public static void ReadReport()
{ {
LoggingService<ReportReadDb>.InfoFormatted("开始读取报表");
DB2107Helper dB2107Helper = new DB2107Helper(); DB2107Helper dB2107Helper = new DB2107Helper();
NormalStatusEntity normal = dB2107Helper.NormalStatus; NormalStatusEntity normal = dB2107Helper.NormalStatus;
if (normal.RdyRpt_D1) if (normal.RdyRpt_D1)

@ -12,6 +12,11 @@ namespace DataBlockHelper.Entity.DB2119Entity
{ {
// OperateResult<byte[]> read = PlcConnect.Instance.Read("DB2102." + startSet + ".0", 2); // OperateResult<byte[]> read = PlcConnect.Instance.Read("DB2102." + startSet + ".0", 2);
if(null== bytes)
{
return;
}
byte[] content = bytes.Skip(startSet).Take(22).ToArray(); byte[] content = bytes.Skip(startSet).Take(22).ToArray();
Value_Set = PlcConnect.Instance.ByteTransform.TransInt16(content, 0); Value_Set = PlcConnect.Instance.ByteTransform.TransInt16(content, 0);

@ -12,6 +12,10 @@ namespace DataBlockHelper.Entity.DB2119Entity
{ {
// OperateResult<byte[]> read = PlcConnect.Instance.Read("DB2102." + startSet + ".0", 2); // OperateResult<byte[]> read = PlcConnect.Instance.Read("DB2102." + startSet + ".0", 2);
if(null == bytes)
{
return;
}
byte[] content = bytes.Skip(startSet).Take(10).ToArray(); byte[] content = bytes.Skip(startSet).Take(10).ToArray();
Value_Set = PlcConnect.Instance.ByteTransform.TransInt16(content, 0); Value_Set = PlcConnect.Instance.ByteTransform.TransInt16(content, 0);

Loading…
Cancel
Save