File tree 1 file changed +7
-3
lines changed
it.baeyens.arduino.common/src/it/baeyens/arduino/arduino
1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -200,10 +200,12 @@ public void connect() {
200
200
}
201
201
if (isMac && !haveVarLock ) {
202
202
Common .log (new Status (IStatus .ERROR , ArduinoConst .CORE_PLUGIN_ID , "Serial port " + PortName
203
- + " not accessible: please run the following command: 'sudo mkdir -p /var/lock && sudo chmod 777 /var/lock'" ));
203
+ + " is not accessible or already in use: try to quit all other programs that may be using it."
204
+ + " If that doesn't fix it, please run the following command:"
205
+ + "\n \n sudo mkdir -p /var/lock && sudo chmod 777 /var/lock\n " ));
204
206
} else {
205
207
Common .log (new Status (IStatus .ERROR , ArduinoConst .CORE_PLUGIN_ID , "Serial port " + PortName
206
- + " already in use. Try quiting any programs that may be using it" , e ));
208
+ + " already in use. Try to quit all other programs that may be using it. " , e ));
207
209
}
208
210
return ;
209
211
} catch (Exception e ) {
@@ -245,7 +247,9 @@ public void disconnect() {
245
247
}
246
248
247
249
public void dispose () {
248
- notifyConsumersOfEvent ("Disconnect of port " + port .getName () + " executed" );
250
+ if (port != null )
251
+ notifyConsumersOfEvent ("Disconnect of port " + port .getName () + " executed" );
252
+
249
253
disconnect ();
250
254
251
255
if (fServiceRegistration != null ) {
You can’t perform that action at this time.
0 commit comments