Skip to content

Commit bb629d1

Browse files
facchinmcmaglie
authored andcommitted
Wait a bit before resuming serial monitor
Helps in case the bootloader port has not yet disappeared when upload completes successfully.
1 parent d154120 commit bb629d1

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

app/src/processing/app/Editor.java

+5
Original file line numberDiff line numberDiff line change
@@ -2091,6 +2091,11 @@ static public boolean isUploading() {
20912091
private void resumeOrCloseSerialMonitor() {
20922092
// Return the serial monitor window to its initial state
20932093
if (serialMonitor != null) {
2094+
try {
2095+
Thread.sleep(200);
2096+
} catch (InterruptedException e) {
2097+
// noop
2098+
}
20942099
BoardPort boardPort = BaseNoGui.getDiscoveryManager().find(PreferencesData.get("serial.port"));
20952100
long sleptFor = 0;
20962101
while (boardPort == null && sleptFor < MAX_TIME_AWAITING_FOR_RESUMING_SERIAL_MONITOR) {

0 commit comments

Comments
 (0)