altoslib: All products with logging have the 'l' command
authorKeith Packard <keithp@keithp.com>
Sat, 7 Jun 2014 18:44:55 +0000 (11:44 -0700)
committerKeith Packard <keithp@keithp.com>
Sat, 7 Jun 2014 19:34:14 +0000 (12:34 -0700)
Instead of listing products with the 'l' command, just exclude
products that don't have logging from using the 'l' command to collect
the number of stored flights.

Signed-off-by: Keith Packard <keithp@keithp.com>
altoslib/AltosConfigData.java

index 2f36e215a36cbac3367382db5c263c3402ce6161..9292a5a2d5b26903e735d9280741fbdb9c91bd60 100644 (file)
@@ -572,12 +572,12 @@ public class AltosConfigData implements Iterable<String> {
                link.printf("c s\nf\nv\n");
                read_link(link, "software-version");
                switch (log_format) {
-               case AltosLib.AO_LOG_FORMAT_FULL:
-               case AltosLib.AO_LOG_FORMAT_TINY:
-               case AltosLib.AO_LOG_FORMAT_TELEMEGA:
+               case AltosLib.AO_LOG_FORMAT_UNKNOWN:
+               case AltosLib.AO_LOG_FORMAT_NONE:
+                       break;
+               default:
                        link.printf("l\n");
                        read_link(link, "done");
-               default:
                        break;
                }
        }