1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00

reconnecting a USB-serial dongle under Linux might give permission errors until udev scripts complete

This commit is contained in:
Antonio Galea 2017-01-12 19:15:05 +01:00
parent 3999d08f8c
commit 2fa4ad3833

View File

@ -601,7 +601,11 @@ class SerCmd(cmd.Cmd):
if os.path.exists(self.port):
self.logger.warn("Try to reconnect to %s again..."
% (self.port))
self.serial_connect()
try:
self.serial_connect()
self.logger.info("Reconnected to serial port %s" % self.port)
except serial.SerialException as se:
pass
continue
if c == '\r':
if (self.newline == "LFCR" and nlreceived) or (self.newline == "CR"):