altos/telelco: Only display every 10th box number during scan
authorKeith Packard <keithp@keithp.com>
Mon, 15 Oct 2012 07:07:57 +0000 (00:07 -0700)
committerKeith Packard <keithp@keithp.com>
Mon, 15 Oct 2012 07:07:57 +0000 (00:07 -0700)
This reduces the scan time to about 4 seconds, which seems tolerable

Signed-off-by: Keith Packard <keithp@keithp.com>
src/telelco-v0.1/ao_lco.c

index ab9f674..df7f865 100644 (file)
@@ -250,7 +250,8 @@ ao_lco_search(void)
        ao_lco_min_box = 0xff;
        ao_lco_max_box = 0x00;
        for (ao_lco_box = 0; ao_lco_box < AO_PAD_MAX_BOXES; ao_lco_box++) {
-               ao_lco_set_box();
+               if ((ao_lco_box % 10) == 0)
+                       ao_lco_set_box();
                r = ao_lco_query(ao_lco_box, &ao_pad_query, &ao_lco_tick_offset);
                if (r == AO_RADIO_CMAC_OK) {
                        if (ao_lco_box < ao_lco_min_box)