summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2011-04-13 20:27:38 -0700
committerKeith Packard <keithp@keithp.com>2011-04-13 20:27:38 -0700
commita0fb471ce10642fc4a4bd40e4a81f8d6fe7a7c21 (patch)
tree11f33e6fdeacb4daaae4b8034fe112f6fe154f93
parent7f49d694e776819e03b2c708e1c4ee23ba311430 (diff)
altosui: oops - lost state changes when downloading eeprom data.
This would cause the reader to just keep reading past the end of the flight. Signed-off-by: Keith Packard <keithp@keithp.com>
-rw-r--r--altosui/AltosEepromDownload.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/altosui/AltosEepromDownload.java b/altosui/AltosEepromDownload.java
index a42f401c..3dd5b12f 100644
--- a/altosui/AltosEepromDownload.java
+++ b/altosui/AltosEepromDownload.java
@@ -155,8 +155,9 @@ public class AltosEepromDownload implements Runnable {
int s = v ^ 0x8000;
if (Altos.ao_flight_startup <= s && s <= Altos.ao_flight_invalid) {
- r = new AltosEepromRecord(Altos.AO_LOG_STATE, tiny_tick, s, 0);
- if (s == Altos.ao_flight_landed)
+ state = s;
+ r = new AltosEepromRecord(Altos.AO_LOG_STATE, tiny_tick, state, 0);
+ if (state == Altos.ao_flight_landed)
done = true;
any_valid = true;
} else {