kopia lustrzana https://github.com/projecthorus/radiosonde_auto_rx
				
				
				
			Merge remote-tracking branch 'upstream/testing' into testing
						commit
						5060c429ff
					
				|  | @ -699,19 +699,21 @@ def read_auto_rx_config(filename, no_sdr_test=False): | |||
| 
 | ||||
| 
 | ||||
|         # 1.6.0 - New SDR options | ||||
|         try: | ||||
|         if not config.has_option("sdr", "sdr_type"): | ||||
|             logging.warning( | ||||
|                 "Config - Missing sdr_type configuration option, defaulting to RTLSDR." | ||||
|             ) | ||||
|             auto_rx_config["sdr_type"] = "RTLSDR" | ||||
|         else: | ||||
|             auto_rx_config["sdr_type"] = config.get("sdr", "sdr_type") | ||||
| 
 | ||||
|         try: | ||||
|             auto_rx_config["sdr_hostname"] = config.get("sdr", "sdr_hostname") | ||||
|             auto_rx_config["sdr_port"] = config.getint("sdr", "sdr_port") | ||||
|             auto_rx_config["ss_iq_path"] = config.get("advanced", "ss_iq_path") | ||||
|             auto_rx_config["ss_power_path"] = config.get("advanced", "ss_power_path") | ||||
|         except: | ||||
|             # Switch this to warning on release... | ||||
|             logging.debug( | ||||
|                 "Config - Did not find new sdr_type and associated options, defaulting to RTLSDR operation." | ||||
|             ) | ||||
|             auto_rx_config["sdr_type"] = "RTLSDR" | ||||
| 
 | ||||
|             logging.debug("Config - Did not find new sdr_type associated options.") | ||||
| 
 | ||||
|         try: | ||||
|             auto_rx_config["always_decode"] = json.loads( | ||||
|  |  | |||
|  | @ -20,9 +20,9 @@ from threading import Thread | |||
| from types import FunctionType, MethodType | ||||
| from .utils import AsynchronousFileReader, rtlsdr_test, position_info, generate_aprs_id | ||||
| from .gps import get_ephemeris, get_almanac | ||||
| from .sonde_specific import * | ||||
| from .sonde_specific import fix_datetime, imet_unique_id | ||||
| from .fsk_demod import FSKDemodStats | ||||
| from .sdr_wrappers import * | ||||
| from .sdr_wrappers import test_sdr, get_sdr_iq_cmd, get_sdr_fm_cmd | ||||
| 
 | ||||
| # Global valid sonde types list. | ||||
| VALID_SONDE_TYPES = [ | ||||
|  |  | |||
|  | @ -23,7 +23,7 @@ from .utils import ( | |||
|     reset_all_rtlsdrs, | ||||
|     peak_decimation, | ||||
| ) | ||||
| from .sdr_wrappers import * | ||||
| from .sdr_wrappers import test_sdr, reset_sdr, get_sdr_name, get_sdr_iq_cmd, get_sdr_fm_cmd, get_power_spectrum | ||||
| 
 | ||||
| 
 | ||||
| try: | ||||
|  |  | |||
|  | @ -10,7 +10,6 @@ import os.path | |||
| import platform | ||||
| import subprocess | ||||
| import numpy as np | ||||
| from io import StringIO | ||||
| 
 | ||||
| from .utils import rtlsdr_test, reset_rtlsdr_by_serial, reset_all_rtlsdrs | ||||
| 
 | ||||
|  | @ -358,7 +357,7 @@ def read_rtl_power_log(log_filename, sdr_name): | |||
| 
 | ||||
|     for line in f: | ||||
|         # Split line into fields. | ||||
|         fields = line.split(",") | ||||
|         fields = line.split(",", 6) | ||||
| 
 | ||||
|         if len(fields) < 6: | ||||
|             logging.error( | ||||
|  | @ -374,9 +373,8 @@ def read_rtl_power_log(log_filename, sdr_name): | |||
|         stop_freq = float(fields[3]) | ||||
|         freq_step = float(fields[4]) | ||||
|         n_samples = int(fields[5]) | ||||
| 
 | ||||
|         # freq_range = np.arange(start_freq,stop_freq,freq_step) | ||||
|         samples = np.loadtxt(StringIO(",".join(fields[6:])), delimiter=",") | ||||
|         samples = np.fromstring(fields[6], sep=",") | ||||
|         freq_range = np.linspace(start_freq, stop_freq, len(samples)) | ||||
| 
 | ||||
|         # Add frequency range and samples to output buffers. | ||||
|  |  | |||
|  | @ -630,7 +630,7 @@ class WebExporter(object): | |||
|         """ Initialise a WebExporter object. | ||||
| 
 | ||||
|         Args: | ||||
|             max_age: Store telemetry data up to X hours old | ||||
|             max_age: Store telemetry data up to X minutes old | ||||
|         """ | ||||
| 
 | ||||
|         self.max_age = max_age * 60 | ||||
|  |  | |||
|  | @ -17,7 +17,7 @@ import argparse | |||
| import glob | ||||
| import os | ||||
| import fastkml | ||||
| from dateutil.parser import * | ||||
| from dateutil.parser import parse | ||||
| from shapely.geometry import Point, LineString | ||||
| 
 | ||||
| def read_telemetry_csv(filename, | ||||
|  |  | |||
|  | @ -1,8 +1,9 @@ | |||
| LDLIBS = -lm | ||||
| 
 | ||||
| PROGRAMS := rs41mod dfm09mod rs92mod lms6mod lms6Xmod meisei100mod m10mod m20mod imet54mod mp3h1mod | ||||
| SRC=$(PROGRAMS:=.c) bch_ecc_mod.c demod_mod.c | ||||
| 
 | ||||
| all: $(PROGRAMS) | ||||
| all: depend $(PROGRAMS) | ||||
| 
 | ||||
| rs41mod: rs41mod.o demod_mod.o bch_ecc_mod.o | ||||
| 
 | ||||
|  | @ -24,10 +25,16 @@ imet54mod: imet54mod.o demod_mod.o | |||
| 
 | ||||
| mp3h1mod: mp3h1mod.o demod_mod.o | ||||
| 
 | ||||
| bch_ecc_mod.o: bch_ecc_mod.h | ||||
| 
 | ||||
| demod_mod.o: CFLAGS += -Ofast | ||||
| demod_mod.o: demod_mod.h | ||||
| 
 | ||||
| depend: .depend | ||||
| 
 | ||||
| .depend: $(SRC) | ||||
| 	$(CC) $(CFLAGS) -MM $^ > .depend | ||||
| 
 | ||||
| -include .depend | ||||
| 
 | ||||
| clean: | ||||
| 	$(RM) $(PROGRAMS) $(PROGRAMS:=.o) demod_mod.o bch_ecc_mod.o | ||||
| 	$(RM) $(PROGRAMS) $(SRC:=.o) | ||||
| 
 | ||||
| .PHONY: all clean depend | ||||
|  |  | |||
		Ładowanie…
	
		Reference in New Issue
	
	 Mark Jessop
						Mark Jessop