资源简介
国外牛人编写的C#modbus协议解析,适合于下位机PLC等。方便您的快速开发
代码片段和文件信息
/****************************************************************************
Modbus - Free .NET Modbus Library
Author : Simone Assunti
License : Freeware open source
*****************************************************************************/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;
using System.IO.Ports;
using System.Net;
using System.Net.Sockets;
using System.Threading;
using System.Reflection;
using System.Diagnostics;
namespace OilField
{
#region Custom Events Args
///
/// Event args for remote endpoint connection
///
public sealed class ModbusTCPUDPClientConnectedEventArgs : EventArgs
{
#region Global Variables
///
/// Remote endpoint
///
IPEndPoint remote_ep;
#endregion
#region Parameters
///
/// Remote EndPoint
///
public IPEndPoint RemoteEndPoint
{
get { return remote_ep; }
}
#endregion
#region Constructor
///
/// Constructor
///
/// Remote EndPoint
public ModbusTCPUDPClientConnectedEventArgs(IPEndPoint remote_ep)
{
this.remote_ep = remote_ep;
}
#endregion
}
#endregion
#region Enumerations
///
/// Connection types
///
public enum ConnectionType
{
///
/// Modbus serial RTU
///
SERIAL_RTU = 0
///
/// Modbus serial ASCII
///
SERIAL_ASCII = 1
///
/// Modbus TCP/IP
///
TCP_IP = 2
///
/// Modbus UDP
///
UDP_IP = 3
}
///
/// Type of modbus serial
///
public enum ModbusSerialType
{
///
/// Modbus RTU
///
RTU = 0
///
/// Modbus ASCII
///
ASCII = 1
}
///
/// Type of device
///
public enum DeviceType
{
///
/// Modbus master
///
MASTER = 0
///
/// Modbus slave
///
SLAVE = 1
}
///
/// Tabelle del database modbus
///
public enum ModbusDBTables
{
DISCRETE_INPUTS_REGISTERS = 0
COIL_REGISTERS = 1
INPUT_REGISTERS = 2
HOLDING_REGISTERS = 3
}
///
/// Modbus calling codes
///
enum
相关资源
- c#实现Modbus tcp客户端
- C# Modbus调试工具源码(RTU协议)
- C# Modbus TCP通讯(S7200PLC)
- Modbus类库C#版本
- c# EasyModbus Client
- Modbus调试工具源码
- modbus tcp 调试
- C#modbus通信
- 松下PLC 通讯(modbus)
- modbus通信
- Modbus通讯 串口通讯
- MODBUS通讯(TCP/Rtu)
- Modbus通讯协议-C#源码
- NModbus_net-3.5_1.11.0.0-source
- C# 开发modbus合集
- Modbus RTU TCP主站从站类库内有说明文档
- NModbusAPI说明文档中文的
- NModbusAPI说明文档中文的 实用
- NModbus说明文档API 中文英文+chm
- modbus tcp/rtu 基于C#的源码实现(老外的
- nmodbus官方例程 包括dllvb.net与C#
- C#使用ModbusTcp协议与西门子1200PLC通讯
- ModBus Tcp 通讯C# +Demo
- C#编成Modbus TCP连接PLC寄存器读取、写
- Modbus_TCP .net C# 通信
- C#封装modbus
- 基于TCP的 modbus , C#源码
- Modbus RTU c#
- NMODBUS PDF
- C# 2015最新版NMODBUS4.0源码支持TCP/IPRT
评论
共有 条评论