public class DeltaTcpNet extends ModbusTcpNet implements IDelta
WordLengthAlienSession, isPersistentConn, IsSocketError, isUseAccountCertificate, LogMsgFormatBinary, simpleHybirdLockCoreSocket, fileCacheSize, LogNet, TokenLogNet| 构造器和说明 |
|---|
DeltaTcpNet() |
DeltaTcpNet(String ipAddress,
int port,
byte station) |
| 限定符和类型 | 方法和说明 |
|---|---|
DeltaSeries |
GetSeries()
获取当前的台达PLC的系列信息,默认为 DVP 系列
Get the current series information of Delta PLC, the default is DVP series |
OperateResultExOne<byte[]> |
Read(String address,
short length)
从Modbus服务器批量读取寄存器的信息,需要指定起始地址,读取长度,如果富文本地址不指定,默认使用的功能码是 0x03,如果需要使用04功能码,那么地址就写成 "x=4;100"
To read the register information from the Modbus server in batches, you need to specify the start address and read length. |
OperateResultExOne<boolean[]> |
ReadBool(String address,
short length)
批量读取线圈或是离散的数据信息,需要指定地址和长度,具体的结果取决于实现,如果富文本地址不指定,默认使用的功能码是 0x01
To read coils or discrete data in batches, you need to specify the address and length. |
void |
SetSeries(DeltaSeries series)
设置当前的台达PLC的系列信息,默认为 DVP 系列
Set the current series information of Delta PLC, the default is DVP series |
String |
toString()
返回表示当前对象的字符串
|
OperateResultExOne<String> |
TranslateToModbusAddress(String address,
byte modbusCode)
将当前的地址信息转换成Modbus格式的地址,如果转换失败,返回失败的消息。
|
OperateResult |
Write(String address,
boolean value)
向线圈中写入bool数值,返回是否写入成功,如果富文本地址不指定,默认使用的功能码是 0x05
Write bool value to the coil and return whether the writing is successful. |
OperateResult |
Write(String address,
boolean[] values)
向线圈中写入bool数组,返回是否写入成功,如果富文本地址不指定,默认使用的功能码是 0x0F
Write the bool array to the coil, and return whether the writing is successful. |
OperateResult |
Write(String address,
byte[] value)
将数据写入到Modbus的寄存器上去,需要指定起始地址和数据内容,如果富文本地址不指定,默认使用的功能码是 0x10
To write data to Modbus registers, you need to specify the start address and data content. |
getAddressStartWithZero, getDataFormat, GetNewNetMessage, getStation, isStringReverse, PackCommandWithHeader, ReadCoil, ReadCoil, ReadDiscrete, ReadDiscrete, setAddressStartWithZero, setDataFormat, setStation, setStringReverse, UnpackResponseContent, Write, WriteMask, WriteOneRegisterReadBool, ReadCustomer, ReadDouble, ReadDouble, ReadFloat, ReadFloat, ReadInt16, ReadInt16, ReadInt32, ReadInt32, ReadInt64, ReadInt64, ReadString, ReadString, ReadUInt16, ReadUInt16, ReadUInt32, ReadUInt32, Write, Write, Write, Write, Write, Write, Write, Write, Write, Write, Write, Write, Write, WriteCustomer, WriteUnicodeString, WriteUnicodeStringAccountCertificate, ConnectClose, ConnectServer, ConnectServer, ExtraAfterReadFromCoreServer, ExtraOnDisconnect, GetAvailableSocket, getByteTransform, getConnectionId, getConnectTimeOut, getIpAddress, getPort, getReceiveTimeOut, getSleepTime, InitializationOnConnect, IpAddressPing, ReadFromCoreServer, ReadFromCoreServer, ReadFromCoreServer, setByteTransform, setConnectionId, setConnectTimeOut, setIpAddress, SetLoginAccount, SetPersistentConnection, setPort, setReceiveTimeOut, setSleepTimeCheckRemoteToken, CloseSocket, CreateSocketAndConnect, CreateSocketAndConnect, CreateSocketAndConnect, ReadStream, Receive, Receive, Receive, ReceiveAndCheckBytes, ReceiveByMessage, ReceiveByMessage, ReceiveBytesContentFromSocket, ReceiveBytesContentFromSocket, ReceiveCommandLineFromSocket, ReceiveCommandLineFromSocket, ReceiveCommandLineFromSocket, ReceiveCommandLineFromSocket, ReceiveFrameWebSocketPayload, ReceiveHslMessage, ReceiveMqttMessage, ReceiveRedisCommand, ReceiveRedisCommandString, ReceiveStringArrayContentFromSocket, ReceiveStringArrayContentFromSocket, ReceiveStringContentFromSocket, ReceiveStringContentFromSocket, ReceiveWebSocketPayload, Send, Send, SendAccountAndCheckReceive, SendBaseAndCheckReceive, SendBytesAndCheckReceive, SendStreamToSocket, SendStringAndCheckReceive, SendStringAndCheckReceive, ThreadPoolCheckTimeOut, WriteStream, WriteStreamFromSocketclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitReadFromCoreServerConnectClose, getConnectionId, ReadBool, ReadCustomer, ReadDouble, ReadDouble, ReadFloat, ReadFloat, ReadInt16, ReadInt16, ReadInt32, ReadInt32, ReadInt64, ReadInt64, ReadString, ReadString, ReadUInt16, ReadUInt16, ReadUInt32, ReadUInt32, setConnectionId, Write, Write, Write, Write, Write, Write, Write, Write, Write, Write, Write, Write, Write, Write, WriteCustomerpublic DeltaTcpNet()
public DeltaTcpNet(String ipAddress, int port, byte station)
public DeltaSeries GetSeries()
IDeltapublic void SetSeries(DeltaSeries series)
IDeltapublic OperateResultExOne<String> TranslateToModbusAddress(String address, byte modbusCode)
IModbusTranslateToModbusAddress 在接口中 IModbusTranslateToModbusAddress 在类中 ModbusTcpNetaddress - 传入的地址modbusCode - Modbus的功能码public OperateResultExOne<boolean[]> ReadBool(String address, short length)
ModbusTcpNetReadBool 在接口中 IReadWriteNetReadBool 在类中 ModbusTcpNetaddress - 数据地址length - 数据长度public OperateResult Write(String address, boolean[] values)
ModbusTcpNetWrite 在接口中 IReadWriteNetWrite 在类中 ModbusTcpNetaddress - 要写入的数据地址values - 要写入的实际数组public OperateResult Write(String address, boolean value)
ModbusTcpNetWrite 在接口中 IReadWriteNetWrite 在类中 ModbusTcpNetaddress - 要写入的数据地址value - 要写入的实际数据public OperateResultExOne<byte[]> Read(String address, short length)
ModbusTcpNetRead 在接口中 IReadWriteNetRead 在类中 ModbusTcpNetaddress - 起始地址,比如"100","x=4;100","s=1;100","s=1;x=4;100"length - 读取的数量public OperateResult Write(String address, byte[] value)
ModbusTcpNetWrite 在接口中 IReadWriteNetWrite 在类中 ModbusTcpNetaddress - 起始地址,比如"100","x=4;100","s=1;100","s=1;x=4;100"value - 写入的数据,长度根据data的长度来指示public String toString()
ModbusTcpNettoString 在类中 ModbusTcpNetCopyright © 2022. All rights reserved.