rossengeorgiev / aprs-python

📡 Python module for working with APRS
http://aprs-python.readthedocs.io/en/latest/
GNU General Public License v2.0
114 stars 37 forks source link

line number ack format not being parsed #58

Closed hemna closed 2 years ago

hemna commented 3 years ago

According to the spec here: http://www.aprs.org/aprs11/replyacks.txt

Message id line number with acks should be parsed out, but don't seem to be.

└─[$] <> cat test-2.py
import aprslib
import pprint
msg = "KO4KWC-6>APRS,TCPIP*,qAC,T2MCI::KO4KWC-14:weather ve3kbr {22}AA"
packet = aprslib.parse(msg)
pprint.pprint(packet)

Results in

└─[$] <> python test-2.py
{'addresse': 'KO4KWC-14',
 'format': 'message',
 'from': 'KO4KWC-6',
 'message_text': 'weather ve3kbr {22}AA',
 'path': ['TCPIP*', 'qAC', 'T2MCI'],
 'raw': 'KO4KWC-6>APRS,TCPIP*,qAC,T2MCI::KO4KWC-14:weather ve3kbr {22}AA',
 'to': 'APRS',
 'via': 'T2MCI'}
joergschultzelutter commented 2 years ago

FWIW, I have a pending pull request which should enable the parser to recognize this 'more recent' format. At the moment, my APRS daemon (which uses Rossen's library) depends on a native post-processing approach in order to parse both old and new formats; this PR should eliminate that need.