fix encoder bug

This commit is contained in:
remilia 2025-04-19 22:45:29 +08:00
parent 0c83418c19
commit b4239c3c74
2 changed files with 4 additions and 4 deletions

View File

@ -133,9 +133,9 @@ class Device(Node):
def get_seq_meta_name(self): def get_seq_meta_name(self):
rb = self.device_cmd(DeviceCmd.GetName) rb = self.device_cmd(DeviceCmd.GetName)
name = rb.decode() if rb != b'' and rb is not None:
self.seq_meta = RfSequenceMeta.from_name(name) name = rb.decode()
if rb != b'': self.seq_meta = RfSequenceMeta.from_name(name)
self.send(SeqMetaMsg('live', name)) self.send(SeqMetaMsg('live', name))
def get_connection(self): def get_connection(self):

View File

@ -60,7 +60,7 @@ class Node:
self.context = zmq.Context() self.context = zmq.Context()
if self.enable_init: if self.enable_init:
self.c = BusClient(*([KillMsg,InterruptMsg, Msg1, Msg2] + self.topics), self.c = BusClient(*([KillMsg, Msg1, Msg2] + self.topics),
poller=True, conflare=self.conflare, req_socket_str=self.req) poller=True, conflare=self.conflare, req_socket_str=self.req)
def __call__(self, *args, **kwargs): def __call__(self, *args, **kwargs):