Skip to content

Commit

Permalink
add exception
Browse files Browse the repository at this point in the history
  • Loading branch information
ykyohei authored and davidvng committed Nov 22, 2024
1 parent 923a772 commit 81ff866
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions socs/agents/hwp_pcu/agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
import time
from dataclasses import dataclass
from queue import Queue
import serial

import serial
import txaio
from twisted.internet import defer, reactor, threads

Expand Down Expand Up @@ -117,7 +117,7 @@ def main(self, session, params):
self.log.info('Connected to PCU')
PCU.clear_buffer()
self.log.info('Cleared buffer')
except ConnectionRefusedError:
except (ConnectionRefusedError, serial.serialutil.SerialException):
self.log.error(
"Could not connect to PCU. "
"Retrying after 30 sec..."
Expand Down

0 comments on commit 81ff866

Please sign in to comment.