Pessoal, boa tarde a todos ! Estou brincando um pouco com robótica e gostaria de saber se alguém já teve o seguinte erro :
java.io.IOException: Underlying input stream returned zero bytes
isso acontece na seguinte parte do meu código:
public synchronized void serialEvent(SerialPortEvent oEvent) {
if (oEvent.getEventType() == SerialPortEvent.DATA_AVAILABLE) {
try {
String inputLine=input.readLine();
System.out.println(inputLine);
} catch (Exception e) {
System.err.println(e.toString());
}
}
// Ignore all the other eventTypes, but you should consider the other ones.
}
Alguém pode me ajudar ??? O programa continua funcionando normalmente, mas essa mensagem fica aparecendo… não sei se pode resultar em algum erro posterior !