Adding more debugging.

This commit is contained in:
Marat Fayzullin 2024-02-28 22:48:32 -05:00
parent 8fdbf90303
commit 8b226a9727
2 changed files with 4 additions and 2 deletions

View File

@ -19,9 +19,10 @@ class DscParser(TextParser):
if self.service:
return None
# Expect JSON data in text form
logger.debug("TEXT: {0}".format(msg))
out = json.loads(msg)
# Add mode name and a color to identify the sender
out["mode"] = "DSC"
out["color"] = self.colors.getColor(out["src"])
logger.debug("{0}".format(out))
logger.debug("JSON: {0}".format(out))
return out

View File

@ -81,8 +81,9 @@ class TextParser(LineBasedModule):
# Compose name of this decoder, made of client/service and frequency
def myName(self):
return "%s%s" % (
return "%s%s%s" % (
"Service" if self.service else "Client",
" " + self.filePfx if self.filePfx else "",
" at %dkHz" % (self.frequency // 1000) if self.frequency>0 else ""
)