using Bro.Common.Base;
|
using Bro.Common.Helper;
|
using System;
|
using System.Collections.Generic;
|
using System.ComponentModel;
|
using System.Linq;
|
using System.Text;
|
using System.Threading.Tasks;
|
|
namespace Bro.Device.OmronFins
|
{
|
[Device("OmronFins", "欧姆龙PLC-Fins通讯", EnumHelper.DeviceAttributeType.OperationConfig)]
|
[Serializable]
|
public class OmronFinsOperationConfig : PLCOperationConfigBase
|
{
|
[ConfigOutputResource("OutputResultCommon")]
|
public override int ResultOutput { get; set; }
|
|
public int StartAddress { get; set; }
|
|
public int OpLength { get; set; }
|
|
public List<int> OpValues { get; set; }
|
}
|
|
public class OmronFinsDeviceConfig : PLCDeviceConfigBase
|
{
|
}
|
|
[DefaultProperty("DNA")]
|
public class OmronFinsInitialConfig : PLCInitialConfigBase
|
{
|
/// <summary>
|
/// PLC网络号
|
/// </summary>
|
[Description("PLC网络号")]
|
[Category("通信设置-PLC")]
|
public byte DNA { get; set; } = 0;
|
|
/// <summary>
|
/// PLC节点号
|
/// </summary>
|
[Description("PLC节点号")]
|
[Category("通信设置-PLC")]
|
public byte DA1 { get; set; } = 1;
|
|
/// <summary>
|
/// PLC单元号
|
/// </summary>
|
[Description("PLC单元号")]
|
[Category("通信设置-PLC")]
|
public byte DA2 { get; set; } = 0;
|
|
/// <summary>
|
/// PLC监听端口
|
/// </summary>
|
[Description("PLC IP地址")]
|
[Category("通信设置-PLC")]
|
public string PLCIpAddress { get; set; }
|
|
/// <summary>
|
/// PLC监听端口
|
/// </summary>
|
[Description("PLC监听端口")]
|
[Category("通信设置-PLC")]
|
public int PLCPort { get; set; } = 9600;
|
|
/// <summary>
|
/// PC网络号
|
/// </summary>
|
[Description("PC网络号")]
|
[Category("通信设置-本机")]
|
public byte SNA { get; set; } = 0;
|
|
/// <summary>
|
/// PC节点号
|
/// </summary>
|
[Description("PC节点号")]
|
[Category("通信设置-本机")]
|
public byte SA1 { get; set; } = 10;
|
|
/// <summary>
|
/// PC单元号
|
/// </summary>
|
[Description("PC单元号")]
|
[Category("通信设置-本机")]
|
public byte SA2 { get; set; } = 0;
|
|
|
}
|
|
public class OmronFinsInputConfig : PLCInputConfigBase
|
{
|
}
|
}
|