diff options
| author | Keith Packard <keithp@keithp.com> | 2010-08-06 13:09:21 -0400 | 
|---|---|---|
| committer | Keith Packard <keithp@keithp.com> | 2010-08-06 13:09:21 -0400 | 
| commit | b7699a5907e64bc7547fcc27e73f4a35bbaabfff (patch) | |
| tree | edf8ecacfb0ea64ddf3b81d8a1adb7e044cd49b9 | |
| parent | 0e917f3ff822616adb147517ac961422e5fedbfd (diff) | |
altosui: Add comments to Eeprom reader
| -rw-r--r-- | ao-tools/altosui/AltosEepromReader.java | 11 | 
1 files changed, 11 insertions, 0 deletions
diff --git a/ao-tools/altosui/AltosEepromReader.java b/ao-tools/altosui/AltosEepromReader.java index 7a8ff5b0..9b928abb 100644 --- a/ao-tools/altosui/AltosEepromReader.java +++ b/ao-tools/altosui/AltosEepromReader.java @@ -36,6 +36,10 @@ import altosui.AltosLog;  import altosui.AltosVoice;  import altosui.AltosEepromMonitor; +/* + * AltosRecords with an index field so they can be sorted by tick while preserving + * the original ordering for elements with matching ticks + */  class AltosOrderedRecord extends AltosEepromRecord implements Comparable<AltosOrderedRecord> {  	int	index; @@ -217,6 +221,13 @@ public class AltosEepromReader {  		}  	} +	/* +	 * Read the whole file, dumping records into a RB tree so +	 * we can enumerate them in time order -- the eeprom data +	 * are sometimes out of order with GPS data getting timestamps +	 * matching the first packet out of the GPS unit but not +	 * written until the final GPS packet has been received. +	 */  	public AltosEepromReader (FileInputStream in_input) {  		state = new AltosRecord();  		state.state = Altos.ao_flight_pad;  | 
