Skip to content

Commit

Permalink
longer reconnect, exc_info
Browse files Browse the repository at this point in the history
  • Loading branch information
ianohara committed Jan 21, 2025
1 parent 28e3774 commit 230198c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions software/control/microcontroller.py
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ def reconnect(self, attempts: int) -> bool:


class MicrocontrollerSerial(AbstractCephlaMicroSerial):
INITIAL_RECONNECT_INTERVAL = 0.1
INITIAL_RECONNECT_INTERVAL = 0.5

@staticmethod
def exponential_backoff_time(attempt_index: int, initial_interval: float) -> float:
Expand Down Expand Up @@ -324,7 +324,7 @@ def reconnect(self, attempts: int) -> bool:
self._serial.open()
except SerialException as se:
self._log.warning(
f"Couldn't reconnect serial={self._serial.port} @ baud={self._serial.baudrate}. Attempt {i + 1}/{attempts}."
f"Couldn't reconnect serial={self._serial.port} @ baud={self._serial.baudrate}. Attempt {i + 1}/{attempts}.", exc_info=se
)
else:
break
Expand Down

0 comments on commit 230198c

Please sign in to comment.