Skip to content

Commit

Permalink
Improve comments for pdoc
Browse files Browse the repository at this point in the history
  • Loading branch information
ianmcorvidae committed Oct 21, 2024
1 parent f08ec18 commit 92a3986
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions meshtastic/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,19 +134,21 @@ class ResponseHandler(NamedTuple):
"""A pending response callback, waiting for a response to one of our messages"""

# requestId: int - used only as a key
#: a callable to call when a response is received
callback: Callable
#: Whether ACKs and NAKs should be passed to this handler
ackPermitted: bool = False
# FIXME, add timestamp and age out old requests


class KnownProtocol(NamedTuple):
"""Used to automatically decode known protocol payloads"""

#: A descriptive name (e.g. "text", "user", "admin")
name: str
# portnum: int, now a key
# If set, will be called to prase as a protocol buffer
#: If set, will be called to parse as a protocol buffer
protobufFactory: Optional[Callable] = None
# If set, invoked as onReceive(interface, packet)
#: If set, invoked as onReceive(interface, packet)
onReceive: Optional[Callable] = None


Expand Down

0 comments on commit 92a3986

Please sign in to comment.