diff --git a/sa_core.c b/sa_core.c index ad23d26..1d46af0 100644 --- a/sa_core.c +++ b/sa_core.c @@ -2457,33 +2457,34 @@ void draw_cal_status(void) y += YSTEP + YSTEP/2 ; buf[0] = ' '; + strcpy(&buf[1],"Scan:"); if (setting.step_delay_mode == SD_PRECISE) buf[0] = 'P'; - if (setting.step_delay_mode == SD_FAST) + else if (setting.step_delay_mode == SD_FAST) buf[0] = 'F'; - strcpy(&buf[1],"Scan:"); + else + strcpy(&buf[0],"Scan:"); ili9341_drawstring(buf, x, y); +#if 0 // Activate for sweep time debugging y += YSTEP; plot_printf(buf, BLEN, "%5.3Fs", (float)setting.sweep_time_us/ONE_SECOND_TIME); ili9341_drawstring(buf, x, y); +#endif y += YSTEP; plot_printf(buf, BLEN, "%5.3Fs", (float)setting.actual_sweep_time_us/ONE_SECOND_TIME); ili9341_drawstring(buf, x, y); -#if 1 +#if 0 // Activate for sweep time debugging y += YSTEP; update_rbw(); // To ensure the calc_min_sweep time shown takes the latest delay into account calculate_step_delay(); uint32_t t = calc_min_sweep_time_us(); -// if (t < setting.sweep_time_us) -// t = setting.sweep_time_us; -// setting.actual_sweep_time_us = t; plot_printf(buf, BLEN, "%5.3Fs", (float)t/ONE_SECOND_TIME); ili9341_drawstring(buf, x, y); + y += YSTEP; plot_printf(buf, BLEN, "%5.3Fs", (float)setting.additional_step_delay_us/ONE_SECOND_TIME); ili9341_drawstring(buf, x, y); - #endif // Cal output diff --git a/ui_sa.c b/ui_sa.c index f26105b..bdc79b8 100644 --- a/ui_sa.c +++ b/ui_sa.c @@ -1364,10 +1364,10 @@ static const menuitem_t menu_harmonic[] = static const menuitem_t menu_scanning_speed[] = { - { MT_CALLBACK, SD_NORMAL, "NORMAL", menu_scanning_speed_cb}, // order must match definition of enum - { MT_CALLBACK, SD_PRECISE, "PRECISE", menu_scanning_speed_cb}, - { MT_CALLBACK | MT_LOW,SD_FAST, "FAST", menu_scanning_speed_cb}, - { MT_KEYPAD | MT_LOW,KM_FAST_SPEEDUP, "FAST\nSPEEDUP", "2..20"}, +// { MT_CALLBACK, SD_NORMAL, "NORMAL", menu_scanning_speed_cb}, // order must match definition of enum +// { MT_CALLBACK, SD_PRECISE, "PRECISE", menu_scanning_speed_cb}, +// { MT_CALLBACK | MT_LOW,SD_FAST, "FAST", menu_scanning_speed_cb}, +// { MT_KEYPAD | MT_LOW,KM_FAST_SPEEDUP, "FAST\nSPEEDUP", "2..20"}, { MT_KEYPAD, KM_SAMPLETIME, "SAMPLE\nDELAY", "300..30000"}, // This must be item 4 to match highlighting { MT_KEYPAD, KM_OFFSET_DELAY, "OFFSET\nDELAY", "300..30000"}, // This must be item 5 to match highlighting { MT_CANCEL, 0, "\032 BACK", NULL }, @@ -1383,12 +1383,12 @@ const menuitem_t menu_sweep_points[] = { static const menuitem_t menu_sweep_speed[] = { - { MT_CALLBACK, SD_NORMAL, "NORMAL", menu_scanning_speed_cb}, // order must match definition of enum - { MT_CALLBACK, SD_PRECISE, "PRECISE", menu_scanning_speed_cb}, - { MT_CALLBACK, SD_FAST, "FAST", menu_scanning_speed_cb}, - { MT_KEYPAD, KM_SWEEP_TIME, "SWEEP\nTIME", "0..600s, 0=disable"}, // This must be item 3 to match highlighting - { MT_SUBMENU, 0, "SWEEP\nPOINTS", menu_sweep_points}, - { MT_KEYPAD | MT_LOW,KM_FAST_SPEEDUP, "FAST\nSPEEDUP", "2..20, 0=disable"}, + { MT_CALLBACK, SD_NORMAL, "NORMAL", menu_scanning_speed_cb}, // order must match definition of enum + { MT_CALLBACK, SD_PRECISE, "PRECISE", menu_scanning_speed_cb}, + { MT_CALLBACK | MT_LOW,SD_FAST, "FAST", menu_scanning_speed_cb}, + { MT_KEYPAD, KM_SWEEP_TIME, "SWEEP\nTIME", "0..600s, 0=disable"}, // This must be item 3 to match highlighting + { MT_SUBMENU, 0, "SWEEP\nPOINTS", menu_sweep_points}, + { MT_KEYPAD | MT_LOW,KM_FAST_SPEEDUP,"FAST\nSPEEDUP", "2..20, 0=disable"}, { MT_CANCEL, 0, "\032 BACK", NULL }, { MT_NONE, 0, NULL, NULL } // sentinel };