Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions RELEASE_NOTES.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,26 @@
# pynmeagps Release Notes

### RELEASE 1.1.5

1. Add support for additional proprietary Quectel PQTM configuration messages from LG290/LG580 firmware version 1.3.

- PQTMAIDINI: Inputs aiding position and time data
- PQTMAIDPOS: Inputs aiding position data
- PQTMAIDTIME: Inputs aiding time data
- PQTMCFGANTENNA: Sets/gets GNSS antenna power supply
- PQTMCFGCNRTHD: Sets/gets the CNR threshold for position engine
- PQTMCFGEVENT: Sets/gets external interrupt event
- PQTMCFGPINALT: Sets/gets the function of module's pin 14
- PQTMCFGPPP: Sets/gets the PPP feature
- PQTMCFGPPS2: Sets/gets the PPS extend feature
- PQTMCFGRTKRL: Sets/gets the RTK reliability level
- PQTMCFGSTANDALONE: Sets/gets the Standalone mode
- PQTMCLRMSG: Disables serial message output. (2 variants)
- PQTMENV: Outputs the environment information.
- PQTMLSTMSG: Queries message output of serial port (2 variants)
- PQTMPPPNAV: Outputs the PPP navigation information
- PQTMRTCMIS: Outputs the RTCM input status

### RELEASE 1.1.4

1. Add `modwno` boolean argument to wnotow2utc and utc2wnotow helper functions - True => modular week number, False => continuous week number. The default is True (modular week no).
Expand Down
2 changes: 1 addition & 1 deletion src/pynmeagps/_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@
:license: BSD 3-Clause
"""

__version__ = "1.1.4"
__version__ = "1.1.5"
44 changes: 44 additions & 0 deletions src/pynmeagps/nmeamessage.py
Original file line number Diff line number Diff line change
Expand Up @@ -356,6 +356,10 @@ def _get_dict_prop(self, key: str, **kwargs) -> dict:
key = self._get_dict_qtmcfgsat(key, self._mode, **kwargs)
elif key == "QTMCFGUART":
key = self._get_dict_qtmcfguart(key, self._mode, **kwargs)
elif key == "QTMCLRMSG":
key = self._get_dict_qtmclrmsg(key, self._mode, **kwargs)
elif key == "QTMLSTMSG":
key = self._get_dict_qtmlstmsg(key, self._mode, **kwargs)
elif key == "QTMSN":
key = self._get_dict_qtmsn(key, self._mode, **kwargs)
elif key == "STMDRSENMSG":
Expand Down Expand Up @@ -397,6 +401,46 @@ def _get_dict_qtmcfguart(self, key: str, mode: int, **kwargs) -> str:
key += "_CURR"
return key

def _get_dict_qtmclrmsg(self, key: str, mode: int, **kwargs) -> str:
"""
Get payload dictionary for proprietary Quectel QTMCLRMSG
command and query variants.

:param str key: msgid
:param int mode: msgmode 1/2
:return: key of payload definition
:rtype: str
"""

lp = len(self._payload)
py = self._streaming
pt = "porttype" in kwargs
pi = "portid" in kwargs
if mode == nmt.SET:
if (py and lp == 0) or (not py and not pt and not pi):
key += "_CURR"
return key

def _get_dict_qtmlstmsg(self, key: str, mode: int, **kwargs) -> str:
"""
Get payload dictionary for proprietary Quectel QTMLSTMSG
command and query variants.

:param str key: msgid
:param int mode: msgmode 1/2
:return: key of payload definition
:rtype: str
"""

lp = len(self._payload)
py = self._streaming
pt = "porttype" in kwargs
pi = "portid" in kwargs
if mode == nmt.POLL:
if (py and lp == 0) or (not py and not pi and not pt):
key += "_CURR"
return key

def _get_dict_qtmcfgmsgrate(self, key: str, mode: int, **kwargs) -> str:
"""
Get payload dictionary for proprietary Quectel QTMCFGMSGRATE
Expand Down
18 changes: 17 additions & 1 deletion src/pynmeagps/nmeatypes_core.py
Original file line number Diff line number Diff line change
Expand Up @@ -523,18 +523,24 @@
# ***************************************************************
# Quectel PQTM Proprietary message types LG290P/LG580P
# ***************************************************************
"QTMAIDINI": "Inputs aiding position and time data",
"QTMAIDPOS": "Inputs aiding position data",
"QTMAIDTIME": "Inputs aiding time data",
"QTMANTENNASTATUS": "Report Antenna Status",
"QTMBKP": "Set Backup Mode",
"QTMCFGAIC": "Sets/Gets AIC Function",
"QTMCFGANTDELTA": "Sets/Gets Delta Between Ref Point and Antenna",
"QTMCFGANTENNA": "Sets/gets GNSS antenna power supply",
"QTMCFGANTINF": "Sets/Gets Antenna Information",
"QTMCFGBLD": "Sets/Gets Baseline Between Two Antennas",
"QTMCFGCNRTHD": "Sets/gets the CNR threshold for position engine",
"QTMCFGCNST": "Sets/Gets Constellation Configuration",
"QTMCFGDR": "Sets/Gets DR State",
"QTMCFGDRHOT": "Sets/Gets DR Hot Start Feature",
"QTMCFGDRRTD": "Sets/Gets DR Running TIme and Distance",
"QTMCFGEINSMSG": "Sets/Gets INS, IMU, GPS Status",
"QTMCFGELETHD": "Sets/Gets Elevation Threshold for Position Engine",
"QTMCFGEVENT": "Sets/gets external interrupt event",
"QTMCFGFIXRATE": "Sets/Gets Fix Interval",
"QTMCFGGEOFENCE": "Sets/Gets Geofence Feature",
"QTMCFGGEOSEP": "Sets/Gets Geoidal Separation",
Expand All @@ -547,24 +553,29 @@
"QTMCFGNMEADP": "Sets/Gets NMEA Precision",
"QTMCFGNMEATID": "Sets/Gets NMEA Talker ID",
"QTMCFGODO": "Sets/Gets Odometer Feature",
"QTMCFGPINALT": "Sets/gets the function of module's pin 14",
"QTMCFGPPP": "Sets/gets the PPP feature",
"QTMCFGPPS": "Sets/Gets PPS (Pulse Per Second) Feature",
"QTMCFGPPS2": "Sets/gets the PPS extend feature",
"QTMCFGPROT": "Sets/Gets I/O Protocol for Specified Port",
"QTMCFGRCVRMODE": "Sets/Gets Receiver Working Mode", # Rover, Base
"QTMCFGRSID": "Sets/Gets Reference Station ID",
"QTMCFGRTCM": "Sets/Gets RTCM",
"QTMCFGRTK": "Sets/Gets RTK Mode", # Absolute, Relative
"QTMCFGRTKRL": "Sets/gets the RTK reliability level",
"QTMCFGRTKSRCTYPE": "Sets/Gets RTK Source Type",
"QTMMCFGRTKSRCTYPE": "Sets/Gets RTK Source Type", # typo in LG580P firmware?
"QTMCFGSAT": "Sets/Gets GNSS Satellite Mask",
"QTMCFGSBAS": "Sets/Gets SBAS",
"QTMCFGSIGGRP": "Sets/Gets GNSS Signal Group",
"QTMCFGSIGNAL": "Sets/Gets Antenna1 Signal Mask",
"QTMCFGSIGNAL2": "Sets/Gets Antenna2 Signal Mask",
"QTMCFGSTANDALONE": "Sets/gets the Standalone mode",
"QTMCFGSTATICHOLD": "Sets/Gets Parking Static Hold",
"QTMCFGSVIN": "Sets/Gets Survey-In Feature", # Survey-In or Fixed
"QTMCFGUART": "Configure UART Interface",
"QTMCFGVEHMOT": "Sets/Gets Vehicle Motion Detection",
"QTMCFGWN": "Sets/Gets Reference Start Week No",
"QTMCLRMSG": "Disables serial message output.",
"QTMCOLD": "Cold Start",
"QTMDEBUGOFF": "Disable Debug Log Output",
"QTMDEBUGON": "Enable Debug Log Output",
Expand All @@ -573,6 +584,7 @@
"QTMDRCLR": "Clear DR Calibration Data",
"QTMDRPVA": "DR Postion, Velosity and Attitude",
"QTMDRSAVE": "Save DR Calibration Data",
"QTMENV": "Outputs the environment information.",
"QTMEOE": "Output End of Epoch Information",
"QTMEPE": "Output Estimated Position Error",
"QTMGEOFENCESTATUS": "Outputs Geofence Status",
Expand All @@ -586,13 +598,17 @@
"QTMINS": "Navigation Results",
"QTMJAMMINGSTATUS": "Jamming Detection Status",
"QTMLS": "Outputs Leap Second Forecast Information",
"QTMLSTMSG": "Queries message output of serial port",
"QTMMCFGRTKSRCTYPE": "Sets/Gets RTK Source Type", # typo in LG580P firmware?
"QTMNAV": "Output Navigation Information",
"QTMODO": "Outputs Odometer Information",
"QTMPL": "Outputs Protection Level Information",
"QTMPPPNAV": "Outputs the PPP navigation information",
"QTMPVT": "Outputs PVT (GNSS) Result", # Position, Velocity, Track
"QTMQVER": "Queries Version Information",
"QTMRESETODO": "Reset Odometer Distance",
"QTMRESTOREPAR": "Restore to Default Values after Restart",
"QTMRTCMIS": "Outputs the RTCM input status",
"QTMSAVEPAR": "Save Configuration to Non-Volatile Memory",
"QTMSENMSG": "Sensor Information",
"QTMSN": "Queries Module Serial Number Code",
Expand Down
156 changes: 156 additions & 0 deletions src/pynmeagps/nmeatypes_get_prop.py
Original file line number Diff line number Diff line change
Expand Up @@ -1391,6 +1391,28 @@
"heading": DE,
},
"QTMDRSAVE": {"status": QS},
"QTMENV": {
"msgver": IN,
"tow": IN,
"wn": IN,
"date": ST,
"time": ST,
"basescore": IN,
"conflevel": DE,
"satvis": IN,
"satslo": IN,
"movedflag": IN,
"movingflag": IN,
"posdiff": ST, # IN
"slotype": IN,
"basesatnum": IN,
"pubsatnum": IN,
"reserved1": IN,
"reserved2": IN,
"reserved3": IN,
"reserved4": IN,
"reserved5": IN,
},
"QTMEOE": {
"msgver": IN, # always 2 for this version
"utc": DE,
Expand Down Expand Up @@ -1547,6 +1569,51 @@
"reserved4": IN,
"pltime": IN,
},
"QTMPPPNAV": {
"msgver": IN,
"timestatus": IN,
"timeref": IN,
"utc": ST,
"date": ST,
"tow": IN,
"wn": IN,
"leapsec": IN,
"datumid": ST,
"reserved1": ST,
"soltype": IN,
"reserved2": ST,
"lat": DE,
"lon": DE,
"alt": DE,
"sep": DE,
"reserved3": ST,
"reserved4": ST,
"latstd": DE,
"lonstd": DE,
"altstd": DE,
"reserved5": ST,
"reserved6": ST,
"diffid": IN,
"diffage": DE,
"reserved7": ST,
"satview": IN,
"satused": IN,
"reserved8": ST,
"reserved9": ST,
"reserved10": ST,
"reserved11": ST,
"reserved12": ST,
"reserved13": ST,
"hvel": DE,
"vvel": DE,
"hvelstd": DE,
"vvelstd": DE,
"reserved14": ST,
"reserved15": ST,
"cog": DE,
"reserved16": ST,
"reserved17": ST,
},
"QTMPVT": {
"msgver": IN, # always 1 for this version
"tow": IN,
Expand All @@ -1568,6 +1635,27 @@
"hdop": DE,
"pdop": DE,
},
"QTMRTCMIS": {
"msgver": IN,
"recvutc": ST,
"porttype": IN,
"portid": IN,
"msgtype": IN,
"subtype": IN,
"refstaid": IN,
"flag": HX,
"msglen": IN,
"msgnum": IN,
"satnum": IN,
"signum": IN,
"siggroup": (
"signum",
{
"sigid": IN,
"sigsatnum": IN,
},
),
},
"QTMQVER": {
"status": QS,
"msgver": IN,
Expand Down Expand Up @@ -1711,6 +1799,74 @@
"builddate": ST, # yyyy/mm/dd
"buildtime": ST, # hh:mm:ss
},
# set and get...
"QTMCFGSTANDALONE": {
"status": QS,
"mode": IN,
"time": IN,
"timeout": IN,
"lat": DE,
"lon": DE,
"alt": DE,
},
"QTMCFGRTKRL": {
"status": QS,
"reliability": IN,
"reserved1": IN,
"reserved2": IN,
"reserved3": IN,
},
"QTMCFGPPS2": {
"status": QS,
"index": IN,
"enable": IN,
"duration": IN,
"mode": IN,
"reserved1": IN,
"period": IN,
"userdelay": IN,
"reserved2": IN,
"reserved3": IN,
"reserved4": IN,
"reserved5": IN,
},
"QTMCFGPPP": {
"status": QS,
"mode": HX,
"datum": IN,
"timeout": IN,
"horstd": DE,
"verstd": DE,
},
"QTMCFGPINALT": {
"status": QS,
"pinnum": IN,
"mode": IN,
},
"QTMCFGEVENT": {
"status": QS,
"index": IN,
"mode": IN,
"edge": IN,
"guard": IN,
},
"QTMCFGCNRTHD": {
"status": QS,
"cnr": DE,
},
"QTMCFGANTENNA": {
"status": QS,
"power": IN,
"reserved": IN,
},
"QTMLSTMSG": {
"status": QS,
"porttype": IN,
"portid": IN,
"msgname": ST,
"rate": IN,
"msgver/offset": IN,
},
# ***************************************************************
# Quectel LG69T PSTM Proprietary message types
# https://quectel.com/content/uploads/2024/09/quectel_lg69taaadafaiajar_gnss_protocol_specification_v1-5.pdf
Expand Down
32 changes: 32 additions & 0 deletions src/pynmeagps/nmeatypes_poll_prop.py
Original file line number Diff line number Diff line change
Expand Up @@ -112,4 +112,36 @@
"QTMUNIQID": {},
"QTMVEHATT": {},
"QTMVERNO": {},
"QTMLSTMSG_CURR": {}, # TODO
"QTMLSTMSG": {
"porttype": IN,
"portid": IN,
}, # TODO
"QTMCFGSTANDALONE": {
"status": QS,
},
"QTMCFGRTKRL": {
"status": QS,
},
"QTMCFGPPS2": {
"status": QS,
"index": IN,
},
"QTMCFGPPP": {
"status": QS,
},
"QTMCFGPINALT": {
"status": QS,
"pinnum": IN,
},
"QTMCFGEVENT": {
"status": QS,
"index": IN,
},
"QTMCFGCNRTHD": {
"status": QS,
},
"QTMCFGANTENNA": {
"status": QS,
},
}
Loading