[Rxtx] reconnecting to serial device
Adam Walsh
adam at grummen.net
Wed Jan 18 18:26:45 MST 2006
Hi Trent,
That fix now allows me to call the close() method (I had to put the
try/catch block around nativeDrain as well because the exception is
thrown for me when I try and flush the output stream). When I call
CommPortIdentifier.isCurrentlyOwned() it returns false as expected, but
when I try and open the port again, I'm getting
gnu.io.PortInUseException: Unknown Application. Any idea why this would
be happening?
Adam
Trent Jarvi wrote:
> On Wed, 18 Jan 2006, Adam Walsh wrote:
>
>> Hi,
>>
>> I'm trying to reconnect to a serial device after it has lost power
>> then been turned on again. I'm using 2.1-7 on win32. If I try and
>> just call CommPortIdentifier.open() again I get a PortInUseException
>> and if I try and call close() on the port first the thread just
>> hangs. Any ideas? Is there some kind of lock that I need to clear first?
>>
>> Thanks for any help!
>>
>
> The fix for this is in CVS now.
>
> http://mailman.qbang.org/pipermail/rxtx/20051229/002014.html
>
More information about the Rxtx
mailing list