10 lines
309 B
Python
10 lines
309 B
Python
from receiver.ascii_receiver import AsciiReceiver
|
|
|
|
|
|
class NmeaReceiver(AsciiReceiver):
|
|
def __init__(self, name: str, tid: str, msg_type: str):
|
|
if tid == "--":
|
|
AsciiReceiver.__init__(self, name, filter=f"^\\$..{msg_type}.*")
|
|
else:
|
|
AsciiReceiver.__init__(self, name, filter=f"^\\${tid}{msg_type}.*")
|