mirror of
https://github.com/craigerl/aprsd.git
synced 2025-06-13 20:02:26 -04:00
updated plugin example
This commit is contained in:
parent
7f2c1d7124
commit
007386505a
@ -1,7 +1,6 @@
|
|||||||
import logging
|
import logging
|
||||||
|
|
||||||
from aprsd import plugin
|
from aprsd import packets, plugin
|
||||||
|
|
||||||
|
|
||||||
LOG = logging.getLogger("APRSD")
|
LOG = logging.getLogger("APRSD")
|
||||||
|
|
||||||
@ -14,7 +13,7 @@ class HelloPlugin(plugin.APRSDRegexCommandPluginBase):
|
|||||||
command_regex = "^[hH]"
|
command_regex = "^[hH]"
|
||||||
command_name = "hello"
|
command_name = "hello"
|
||||||
|
|
||||||
def process(self, packet):
|
def process(self, packet: packets.MessagePacket):
|
||||||
LOG.info("HelloPlugin")
|
LOG.info("HelloPlugin")
|
||||||
reply = f"Hello '{packet.from_call}'"
|
reply = f"Hello '{packet.from_call}'"
|
||||||
return reply
|
return reply
|
||||||
|
Loading…
x
Reference in New Issue
Block a user