diff options
author | Keith Packard <keithp@keithp.com> | 2017-10-02 16:55:18 -0700 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2017-10-02 16:55:18 -0700 |
commit | de2b6ec1cdfd48c948bff7edbfe2540440429b1b (patch) | |
tree | aa9754d515f020a6992ff4787e936be466bc9799 /altoslib/AltosTelemetryReader.java | |
parent | 322c1abead39cb398380dff384cd274c19dd81dd (diff) |
altoslib,altosuilib,altosui: log_format/device_type TeleGPS selects stateless
When the device being analyzed has no flight state, we want to use the
'stateless' state so that the UI can display reasonable
information. This bit was lost in the recent AltosState shuffle and
this patch brings it back.
Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'altoslib/AltosTelemetryReader.java')
-rw-r--r-- | altoslib/AltosTelemetryReader.java | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/altoslib/AltosTelemetryReader.java b/altoslib/AltosTelemetryReader.java index 26fe4f26..8fb61a4f 100644 --- a/altoslib/AltosTelemetryReader.java +++ b/altoslib/AltosTelemetryReader.java @@ -41,19 +41,15 @@ public class AltosTelemetryReader extends AltosFlightReader { throw new IOException("IO error"); } while (!link.get_monitor()); AltosTelemetry telem = AltosTelemetry.parse(l.line); - if (state == null) { - System.out.printf("Make state\n"); + if (state == null) state = new AltosState(cal_data()); - } telem.provide_data(state); return state; } public AltosCalData cal_data() { - if (cal_data == null) { - System.out.printf("Make cal data\n"); + if (cal_data == null) cal_data = new AltosCalData(); - } return cal_data; } |