You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
|
using HybirdFrameworkCore.Autofac.Attribute;
|
|
|
|
|
using System;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.Linq;
|
|
|
|
|
using System.Text;
|
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
|
|
|
|
|
namespace HybirdFrameworkServices.Plc
|
|
|
|
|
{
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 可读可写区
|
|
|
|
|
/// </summary>
|
|
|
|
|
public class PlcReadAndWrite1
|
|
|
|
|
{
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 写编程使能 写 0x5AA5,打开写使能
|
|
|
|
|
/// </summary>
|
|
|
|
|
[Property(0, 2, PropertyReadConstant.Byte)]
|
|
|
|
|
public ushort ProgrammingEnable { get; set; }
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 本机modbus地址
|
|
|
|
|
/// </summary>
|
|
|
|
|
[Property(2, 2, PropertyReadConstant.Byte)]
|
|
|
|
|
public ushort Modbus1Addres { get; set; }
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 波特率
|
|
|
|
|
/// <para>0:1200</para>
|
|
|
|
|
/// <para>1:2400</para>
|
|
|
|
|
/// <para>2:4800</para>
|
|
|
|
|
/// <para>3:9600</para>
|
|
|
|
|
/// <para>4:19200</para>
|
|
|
|
|
/// </summary>
|
|
|
|
|
[Property(4, 2, PropertyReadConstant.Byte)]
|
|
|
|
|
public ushort BaudRate { get; set; }
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 校验位
|
|
|
|
|
/// <para>0:无</para>
|
|
|
|
|
/// <para>1:奇</para>
|
|
|
|
|
/// <para>2:偶</para>
|
|
|
|
|
/// </summary>
|
|
|
|
|
//[Property(2, 2, PropertyReadConstant.Byte)]
|
|
|
|
|
public ushort CheckBit { get; set; }
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 秒脉冲/无功电能选择
|
|
|
|
|
/// 0x5A02:秒脉冲输出
|
|
|
|
|
/// 其他:无功电能输出)
|
|
|
|
|
/// </summary>
|
|
|
|
|
//[Property(2, 2, PropertyReadConstant.Byte)]
|
|
|
|
|
public ushort PulsePerSecond { get; set; }
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 电流接线反向
|
|
|
|
|
/// <para>0x00:不反接(默认值) </para>
|
|
|
|
|
/// <para>0x01:反接</para>
|
|
|
|
|
/// </summary>
|
|
|
|
|
//[Property(2, 2, PropertyReadConstant.Byte)]
|
|
|
|
|
public ushort CurrentReversal { get; set; }
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 电表清零
|
|
|
|
|
/// 写 0x0000 清零,其他不清
|
|
|
|
|
/// </summary>
|
|
|
|
|
//[Property(2, 2, PropertyReadConstant.Byte)]
|
|
|
|
|
public ushort MeterReset { get; set; }
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}
|