private static IModbusCommand Parse05(byte slave, byte code, ushort address, byte[] request, int offset) { var value = ModbusHelper.DecodeBool(request[offset + 4]); var zero = request[offset + 5]; Tools.AssertEqual(zero, 0, "Zero mismatch got {0} expected {1}"); return(new ModbusF05WriteCoil(slave, address, value)); }