arduino / WiFi101-FirmwareUpdater-Plugin

WiFi101 Firmware Updater Tool for Arduino IDE
13 stars 23 forks source link

Make "openPort (); Exception type - Port busy." error messages more friendly #19

Closed ghost closed 5 years ago

ghost commented 6 years ago

Problems with WiFi Firmware Updater When I run the CheckWifi101FrimwareVersion sample I get the following: WiFi101 shield: DETECTED Firmware version installed: 19.4.4 Latest firmware version available: 19.5.4

Check result: NOT PASSED

When I do a 'Test connection' (Wifi101 Firmware/Certificates Updater Window) an error occurs:

jssc.SerialPortException: Port name - COM3; Method name - closePort (); Exception type - Port not opened.
at jssc.SerialPort.checkPortOpened (SerialPort.java:878)
at jssc.SerialPort.closePort (SerialPort.java:1088)
at cc.arduino.plugins.wifi101.flashers.java.FlasherSerialClient.close (FlasherSerialClient.java:98)
at cc.arduino.plugins.wifi101.flashers.java.JavaFlasher.testConnection (JavaFlasher.java:56)
at cc.arduino.plugins.wifi101.UpdaterImpl $ 2.run (UpdaterImpl.java:110)
processing.app.SerialException: Error opening port "COM3"
at cc.arduino.plugins.wifi101.flashers.java.FlasherSerialClient.open (FlasherSerialClient.java:86)
at cc.arduino.plugins.wifi101.flashers.java.JavaFlasher.testConnection (JavaFlasher.java:50)
at cc.arduino.plugins.wifi101.UpdaterImpl $ 2.run (UpdaterImpl.java:110)
Caused by: jssc.SerialPortException: Port name - COM3; Method name - openPort (); Exception type - Port busy.
at jssc.SerialPort.openPort (SerialPort.java:164)
at cc.arduino.plugins.wifi101.flashers.java.FlasherSerialClient.open (FlasherSerialClient.java:54)
... 2 more

What can be happening?

Thank you very much for the help.

facchinm commented 6 years ago

Hi @Josua2012 , which IDE version are you running? If you can, try downloading the hourly build https://www.arduino.cc/en/Main/Software#hourly and check if the problem is gone. Before running the updater, you need to flash the FirmwareUpdater sketch if you haven't already

Miq1 commented 6 years ago

Same issue here. I am using the beta 1.9.0 IDE.

In the meantime tried it with the Hourly Build of Aug 14th - same issue, the IDE seems to not be involved.

sandeepmistry commented 6 years ago

Caused by: jssc.SerialPortException: Port name - COM3; Method name - openPort (); Exception type - Port busy.

Is the serial monitor open? (or does another program have it open?)

Miq1 commented 6 years ago

I cannot answer for the original poster, but yes, in my case it was. And guess what? That solved it!

Thanks a lot - I should have thought of that myself... ;-)

sandeepmistry commented 6 years ago

@Miq1 cool, let's leave this issue open for now, I've changed the title to indicate we can have a friendlier error message when this happens.