mirror of
https://github.com/arduino/Arduino.git
synced 2025-01-21 10:52:14 +01:00
Wait a bit before resuming serial monitor
Helps in case the bootloader port has not yet disappeared when upload completes successfully.
This commit is contained in:
parent
d154120f0e
commit
bb629d1ba0
@ -2091,6 +2091,11 @@ public class Editor extends JFrame implements RunnerListener {
|
||||
private void resumeOrCloseSerialMonitor() {
|
||||
// Return the serial monitor window to its initial state
|
||||
if (serialMonitor != null) {
|
||||
try {
|
||||
Thread.sleep(200);
|
||||
} catch (InterruptedException e) {
|
||||
// noop
|
||||
}
|
||||
BoardPort boardPort = BaseNoGui.getDiscoveryManager().find(PreferencesData.get("serial.port"));
|
||||
long sleptFor = 0;
|
||||
while (boardPort == null && sleptFor < MAX_TIME_AWAITING_FOR_RESUMING_SERIAL_MONITOR) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user