def do_start(self, params):
if self.device and not self._run:
try:
self.socket = socket.socket(socket.PF_CAN, socket.SOCK_RAW, socket.CAN_RAW)
self.socket.setblocking(0)
self.socket.bind((self.device,))
self._run = True
except Exception as e:
self._run = False
self.dprint(0, "ERROR: " + str(e))
self.set_error_text("ERROR: " + str(e))
traceback.print_exc()
评论列表
文章目录