This commit is contained in:
parallelbgls
2017-06-14 17:02:38 +08:00
parent 5a473dd09e
commit 74e06cbc6e
2 changed files with 41 additions and 1 deletions

View File

@@ -410,7 +410,7 @@ namespace Modbus.Net.Modbus
FunctionCode == (byte) ModbusProtocalWriteDataFunctionCode.WriteSingleCoil
? ((bool) writeValue
? new byte[] {0xFF, 0x00}
: new byte[] {0x00, 0xFF})
: new byte[] {0x00, 0x00})
: ValueHelper.GetInstance(endian).GetBytes(ushort.Parse(writeValue.ToString()));
WriteValue = writeByteValue;
}