kopia lustrzana https://github.com/projecthorus/horusdemodlib
Disable habitat uploader, add warning when uploading 4FSKTEST telemetry
rodzic
b3a4537551
commit
50d7e18bed
|
@ -1 +1 @@
|
||||||
__version__ = "0.3.9"
|
__version__ = "0.3.10"
|
||||||
|
|
|
@ -170,6 +170,9 @@ class SondehubAmateurUploader(object):
|
||||||
self.log_error("Not uploading telemetry from unknown payload ID. Is your payload ID list old?")
|
self.log_error("Not uploading telemetry from unknown payload ID. Is your payload ID list old?")
|
||||||
return None
|
return None
|
||||||
|
|
||||||
|
if '4FSKTEST' in telemetry['callsign']:
|
||||||
|
self.log_warning(f"Payload ID {telemetry['callsign']} is for testing purposes only, and should not be used on an actual flight. Refer here: https://github.com/projecthorus/horusdemodlib/wiki#how-do-i-transmit-it")
|
||||||
|
|
||||||
_output['payload_callsign'] = telemetry["callsign"]
|
_output['payload_callsign'] = telemetry["callsign"]
|
||||||
|
|
||||||
# Frame Number
|
# Frame Number
|
||||||
|
@ -456,6 +459,13 @@ class SondehubAmateurUploader(object):
|
||||||
"""
|
"""
|
||||||
logging.error("Sondehub Amateur Uploader - %s" % line)
|
logging.error("Sondehub Amateur Uploader - %s" % line)
|
||||||
|
|
||||||
|
def log_warning(self, line):
|
||||||
|
""" Helper function to log a warning message with a descriptive heading.
|
||||||
|
Args:
|
||||||
|
line (str): Message to be logged.
|
||||||
|
"""
|
||||||
|
logging.warning("Sondehub Amateur Uploader - %s" % line)
|
||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
# Test Script
|
# Test Script
|
||||||
|
|
|
@ -121,14 +121,15 @@ def main():
|
||||||
else:
|
else:
|
||||||
_listener_freq_str = ""
|
_listener_freq_str = ""
|
||||||
|
|
||||||
habitat_uploader = HabitatUploader(
|
# Habitat uploader disabled as of 2022-12-18
|
||||||
user_callsign = user_config['user_call'],
|
# habitat_uploader = HabitatUploader(
|
||||||
listener_lat = user_config['station_lat'],
|
# user_callsign = user_config['user_call'],
|
||||||
listener_lon = user_config['station_lon'],
|
# listener_lat = user_config['station_lat'],
|
||||||
listener_radio = user_config['radio_comment'] + _listener_freq_str,
|
# listener_lon = user_config['station_lon'],
|
||||||
listener_antenna = user_config['antenna_comment'],
|
# listener_radio = user_config['radio_comment'] + _listener_freq_str,
|
||||||
inhibit=args.noupload
|
# listener_antenna = user_config['antenna_comment'],
|
||||||
)
|
# inhibit=args.noupload
|
||||||
|
# )
|
||||||
|
|
||||||
if user_config['station_lat'] == 0.0 and user_config['station_lon'] == 0.0:
|
if user_config['station_lat'] == 0.0 and user_config['station_lon'] == 0.0:
|
||||||
_sondehub_user_pos = None
|
_sondehub_user_pos = None
|
||||||
|
@ -183,7 +184,7 @@ def main():
|
||||||
# Add in frequency estimate, if we have been supplied a receiver frequency.
|
# Add in frequency estimate, if we have been supplied a receiver frequency.
|
||||||
if args.freq_hz:
|
if args.freq_hz:
|
||||||
_decoded['f_centre'] = int(demod_stats.fest_mean) + int(args.freq_hz)
|
_decoded['f_centre'] = int(demod_stats.fest_mean) + int(args.freq_hz)
|
||||||
habitat_uploader.last_freq_hz = _decoded['f_centre']
|
#habitat_uploader.last_freq_hz = _decoded['f_centre']
|
||||||
|
|
||||||
# Add in baud rate, if provided.
|
# Add in baud rate, if provided.
|
||||||
if args.baud_rate:
|
if args.baud_rate:
|
||||||
|
@ -193,8 +194,8 @@ def main():
|
||||||
send_payload_summary(_decoded, port=user_config['summary_port'])
|
send_payload_summary(_decoded, port=user_config['summary_port'])
|
||||||
|
|
||||||
# Upload the string to Habitat
|
# Upload the string to Habitat
|
||||||
_decoded_str = "$$" + data.split('$')[-1] + '\n'
|
#_decoded_str = "$$" + data.split('$')[-1] + '\n'
|
||||||
habitat_uploader.add(_decoded_str)
|
#habitat_uploader.add(_decoded_str)
|
||||||
|
|
||||||
# Upload the string to Sondehub Amateur
|
# Upload the string to Sondehub Amateur
|
||||||
sondehub_uploader.add(_decoded)
|
sondehub_uploader.add(_decoded)
|
||||||
|
@ -232,7 +233,7 @@ def main():
|
||||||
# Add in frequency estimate, if we have been supplied a receiver frequency.
|
# Add in frequency estimate, if we have been supplied a receiver frequency.
|
||||||
if args.freq_hz:
|
if args.freq_hz:
|
||||||
_decoded['f_centre'] = int(demod_stats.fest_mean) + int(args.freq_hz)
|
_decoded['f_centre'] = int(demod_stats.fest_mean) + int(args.freq_hz)
|
||||||
habitat_uploader.last_freq_hz = _decoded['f_centre']
|
#habitat_uploader.last_freq_hz = _decoded['f_centre']
|
||||||
|
|
||||||
# Add in baud rate, if provided.
|
# Add in baud rate, if provided.
|
||||||
if args.baud_rate:
|
if args.baud_rate:
|
||||||
|
@ -258,7 +259,7 @@ def main():
|
||||||
except KeyboardInterrupt:
|
except KeyboardInterrupt:
|
||||||
logging.info("Caught CTRL-C, exiting.")
|
logging.info("Caught CTRL-C, exiting.")
|
||||||
|
|
||||||
habitat_uploader.close()
|
#habitat_uploader.close()
|
||||||
sondehub_uploader.close()
|
sondehub_uploader.close()
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
[tool.poetry]
|
[tool.poetry]
|
||||||
name = "horusdemodlib"
|
name = "horusdemodlib"
|
||||||
version = "0.3.9"
|
version = "0.3.10"
|
||||||
description = "Project Horus HAB Telemetry Demodulators"
|
description = "Project Horus HAB Telemetry Demodulators"
|
||||||
authors = ["Mark Jessop"]
|
authors = ["Mark Jessop"]
|
||||||
license = "LGPL-2.1-or-later"
|
license = "LGPL-2.1-or-later"
|
||||||
|
|
|
@ -3,8 +3,7 @@
|
||||||
#
|
#
|
||||||
|
|
||||||
[user]
|
[user]
|
||||||
# Your callsign - used when uploading to the HabHub Tracker.
|
# Your callsign - used when uploading to the SondeHub-Amateur Tracker
|
||||||
# Note that we now also upload to the experimental SondeHub Amateur DB as well by default.
|
|
||||||
callsign = YOUR_CALL_HERE
|
callsign = YOUR_CALL_HERE
|
||||||
|
|
||||||
# Your station latitude/longitude, which will show up on tracker.habhub.org.
|
# Your station latitude/longitude, which will show up on tracker.habhub.org.
|
||||||
|
|
Ładowanie…
Reference in New Issue