You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Apparently it's the error stream in the processbuilder that was hanging the program so I added the following:
pb.redirectErrorStream(true);
so the error stream is redirected in the output stream and the program didn't hang any more.
After that, I had some problems reading the stream. 2 device names were alphanumeric and didn't start with "Received":
Recei30000 and
ved I-Am Request from 303013...
It's weird that the 30000 goes and mix the "Received I-Am Request from 303013". Maybe some kind of synchronization problem.
My solution was to remove the throw new IllegalActionException in the catch NumberFormatException so it continues to read all the
device names even if some of them have errors.
With those 2 corrections, everything works correctly on my computer. But that doesn't explain why it works correctly on your computer.
It would be nice if you could send me BACnetDeviceManager.java from your BCVTB folder so I could compare what's different.
I'm using Java jdk1.6.0_20
The text was updated successfully, but these errors were encountered:
Original reporter: mwetter
The BACnet reader hangs. The user error report is:
My computer runs on Windows XP 32bits and I my firewall is off.
I traced throught the code to find where it was hanging. It's hanging in BACnetDeviceManager class in findDevice() method.
The buffered reader that reads the output from the ProcessBuilder was never in a ready state. I did some research about that
and found that webpage:
http://stackoverflow.com/questions/3159913/problem-reading-inputstream-from-java-process-runtime-getruntime-exec-or-pro
Apparently it's the error stream in the processbuilder that was hanging the program so I added the following:
pb.redirectErrorStream(true);
so the error stream is redirected in the output stream and the program didn't hang any more.
After that, I had some problems reading the stream. 2 device names were alphanumeric and didn't start with "Received":
Recei30000 and
ved I-Am Request from 303013...
It's weird that the 30000 goes and mix the "Received I-Am Request from 303013". Maybe some kind of synchronization problem.
My solution was to remove the throw new IllegalActionException in the catch NumberFormatException so it continues to read all the
device names even if some of them have errors.
With those 2 corrections, everything works correctly on my computer. But that doesn't explain why it works correctly on your computer.
It would be nice if you could send me BACnetDeviceManager.java from your BCVTB folder so I could compare what's different.
I'm using Java jdk1.6.0_20
The text was updated successfully, but these errors were encountered: