| | |
javax.comm write error
![]() |
I recently bumped into this interesting problem when writing code that used serial port communications. Writing data to serial port fails after ~ 30 seconds of use. Everything works fine for the first 30 seconds or so, then an IOException: write error occurs.
I am writing data to the OutputStream a serial port configured like this:
This problem is similarly described in these Sun Java Forums. However, no one seems to have a solution to this problem, and those forum threads died long ago. I hope dani's community might have some answers.
http://forum.java.sun.com/thread.jsp...message=817968
http://forum.java.sun.com/thread.jsp...essage=1104701
Below is a snip of the output as well as the stack trace:
Perhaps this is a java bug that I should report, but I just want to be sure.
Ed
I am writing data to the OutputStream a serial port configured like this:
Java Syntax (Toggle Plain Text)
fSerialPort.setFlowControlMode(SerialPort.FLOWCONTROL_NONE); fSerialPort.setSerialPortParams(baudrate, SerialPort.DATABITS_8, SerialPort.STOPBITS_1, SerialPort.PARITY_NONE);
This problem is similarly described in these Sun Java Forums. However, no one seems to have a solution to this problem, and those forum threads died long ago. I hope dani's community might have some answers.
http://forum.java.sun.com/thread.jsp...message=817968
http://forum.java.sun.com/thread.jsp...essage=1104701
Below is a snip of the output as well as the stack trace:
Java Syntax (Toggle Plain Text)
COMM|Sending: Ask for Embedded Status. Header: 4 0 12 8 java.io.IOException: write error at com.sun.comm.Win32SerialPort.write(Win32SerialPort.java:677) at com.sun.comm.Win32SerialOutputStream.write(Win32SerialOutputStream.java:43) at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:66) at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:124) at edu.dartmouth.robot.tenzing.comm.TimerSender.send(TimerSender.java:103) at edu.dartmouth.robot.tenzing.comm.RobotComm.run(RobotComm.java:157)
Perhaps this is a java bug that I should report, but I just want to be sure.
Ed
•
•
•
•
In a world without walls or fences,
What use are Windows and Gates.
![]() |
Similar Threads
- Javamail javax.mail.FolderClosedException error (Java)
- Unix extract write error (*nix Hardware Configuration)
- java.net.SocketException: Connection reset by peer: socket write error (Java)
- rs232 to usb comm question (C++)
- parallel port trouble. (Java)
- Javax.comm, RXTX, jUSB, javax.usb (Java)
- Memory read/write error when opening programs. (Windows NT / 2000 / XP)
Other Threads in the Java Forum
- Previous Thread: Applet Help
- Next Thread: Help Needed ! ! !
| Thread Tools | Search this Thread |
911 actionlistener addressbook android api append applet application array arrays automation binary blackberry block bluetooth character chat class client code component consumer csv database desktop developmenthelp eclipse error fractal ftp game givemetehcodez graphics gui html ide image integer j2me j2seprojects japplet java javaarraylist javac javaee javaprojects jni jpanel julia lego linked linux list loops mac map method methods mobile netbeans newbie number objects online oriented panel printf problem program programming project projects properties recursion replaydirector reporting researchinmotion rotatetext rsa scanner se server set singleton sms sort sql string swing test textfields threads time title tree tutorial-sample ubuntu update windows working





