diff options
author | Keith Packard <keithp@keithp.com> | 2012-09-12 21:32:25 -0700 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2012-09-12 21:35:34 -0700 |
commit | 7e237920abb582d7ceb3e1925b11a848575ac68a (patch) | |
tree | 61725c0a154ab8aebca7491504856671130970b1 | |
parent | 07d9ba938f2742da1bce5d8df55cbc236207a981 (diff) |
altosui: Stop downloading eeprom data on a block full of invalid data
When no valid records are found within an eeprom block, we assume that
no more data will be found within the entire storage area.
Signed-off-by: Keith Packard <keithp@keithp.com>
-rw-r--r-- | altosui/AltosEepromDownload.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/altosui/AltosEepromDownload.java b/altosui/AltosEepromDownload.java index b04890cd..65cac7bd 100644 --- a/altosui/AltosEepromDownload.java +++ b/altosui/AltosEepromDownload.java @@ -134,7 +134,8 @@ public class AltosEepromDownload implements Runnable { } if (r.cmd == Altos.AO_LOG_STATE && r.a == Altos.ao_flight_landed) done = true; - any_valid = true; + if (r.cmd != AltosLib.AO_LOG_INVALID) + any_valid = true; Log(r); } catch (ParseException pe) { if (parse_exception == null) |