From 8801b8c1947bd39f7c985b91a2ba8dbc81bcc91a Mon Sep 17 00:00:00 2001 From: Keith Packard Date: Wed, 12 Jan 2011 12:40:45 -0800 Subject: altosui: Add eeprom 'manage' ui to download and delete multiple flights This shows the list of available flights and provides options to download and/or delete each one. Signed-off-by: Keith Packard --- altosui/AltosEepromLog.java | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'altosui/AltosEepromLog.java') diff --git a/altosui/AltosEepromLog.java b/altosui/AltosEepromLog.java index 36289b42..f284f103 100644 --- a/altosui/AltosEepromLog.java +++ b/altosui/AltosEepromLog.java @@ -30,6 +30,10 @@ import java.util.concurrent.*; import libaltosJNI.*; +/* + * Extract a bit of information from an eeprom-stored flight log. + */ + public class AltosEepromLog { int serial; boolean has_flight; @@ -42,6 +46,9 @@ public class AltosEepromLog { int hour, minute, second; double lat, lon; + boolean download; + boolean delete; + public AltosEepromLog(AltosSerial serial_line, int in_serial, int in_start_block, int in_end_block) throws InterruptedException, TimeoutException { @@ -53,6 +60,15 @@ public class AltosEepromLog { end_block = in_end_block; serial = in_serial; + /* + * By default, request that every log be downloaded but not deleted + */ + download = true; + delete = false; + /* + * Only look in the first two blocks so that this + * process doesn't take a long time + */ if (in_end_block > in_start_block + 2) in_end_block = in_start_block + 2; -- cgit v1.2.3