steveohara / j2mod

Enhanced Modbus library implemented in the Java programming language
Apache License 2.0
265 stars 111 forks source link

getConnection.isOpen() still true after serial-port removal #74

Closed orensharon closed 6 years ago

orensharon commented 6 years ago

When I'm disconnecting the serial port (using RTU) from my pc - I want to know about it. I'm trying to detect disconnections of the serial com port using: getConnection.isOpen()

If I had serial connection and now its gone - getConnection.isOpen() still returns true.

https://github.com/steveohara/j2mod/blob/4d17481856192b6550fcf80428f9eda50468d9a2/src/main/java/com/ghgande/j2mod/modbus/net/SerialConnection.java#L167

Thanks

steveohara commented 6 years ago

Fixed in tonight's snapshot release