mirror of
https://github.com/ttrftech/NanoVNA.git
synced 2025-12-06 03:31:59 +01:00
fix segv on active trace 4, apply error term inside sweep loop, show active trace on marker info
This commit is contained in:
parent
8ce6b7b6e0
commit
043972e6ca
45
main.c
45
main.c
|
|
@ -34,6 +34,8 @@
|
||||||
#define ENABLED_DUMP
|
#define ENABLED_DUMP
|
||||||
|
|
||||||
static void apply_error_term(void);
|
static void apply_error_term(void);
|
||||||
|
static void apply_error_term_at(int i);
|
||||||
|
|
||||||
void sweep(void);
|
void sweep(void);
|
||||||
|
|
||||||
static MUTEX_DECL(mutex);
|
static MUTEX_DECL(mutex);
|
||||||
|
|
@ -44,6 +46,7 @@ uint8_t drive_strength = SI5351_CLK_DRIVE_STRENGTH_2MA;
|
||||||
int8_t frequency_updated = FALSE;
|
int8_t frequency_updated = FALSE;
|
||||||
int8_t sweep_enabled = TRUE;
|
int8_t sweep_enabled = TRUE;
|
||||||
int8_t cal_auto_interpolate = TRUE;
|
int8_t cal_auto_interpolate = TRUE;
|
||||||
|
int8_t redraw_requested = FALSE;
|
||||||
|
|
||||||
static THD_WORKING_AREA(waThread1, 768);
|
static THD_WORKING_AREA(waThread1, 768);
|
||||||
static THD_FUNCTION(Thread1, arg)
|
static THD_FUNCTION(Thread1, arg)
|
||||||
|
|
@ -474,15 +477,22 @@ void sweep(void)
|
||||||
|
|
||||||
// blink LED while scanning
|
// blink LED while scanning
|
||||||
palSetPad(GPIOC, GPIOC_LED);
|
palSetPad(GPIOC, GPIOC_LED);
|
||||||
|
|
||||||
|
if (cal_status & CALSTAT_APPLY)
|
||||||
|
apply_error_term_at(i);
|
||||||
|
|
||||||
|
redraw_requested = FALSE;
|
||||||
ui_process();
|
ui_process();
|
||||||
|
if (redraw_requested)
|
||||||
|
return; // return to redraw screen asap.
|
||||||
|
|
||||||
if (frequency_updated)
|
if (frequency_updated)
|
||||||
goto rewind;
|
goto rewind;
|
||||||
}
|
}
|
||||||
set_frequency(frequencies[0]);
|
set_frequency(frequencies[0]);
|
||||||
|
|
||||||
if (cal_status & CALSTAT_APPLY)
|
//if (cal_status & CALSTAT_APPLY)
|
||||||
apply_error_term();
|
// apply_error_term();
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
@ -830,6 +840,35 @@ void apply_error_term(void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void apply_error_term_at(int i)
|
||||||
|
{
|
||||||
|
// S11m' = S11m - Ed
|
||||||
|
// S11a = S11m' / (Er + Es S11m')
|
||||||
|
float s11mr = measured[0][i][0] - cal_data[ETERM_ED][i][0];
|
||||||
|
float s11mi = measured[0][i][1] - cal_data[ETERM_ED][i][1];
|
||||||
|
float err = cal_data[ETERM_ER][i][0] + s11mr * cal_data[ETERM_ES][i][0] - s11mi * cal_data[ETERM_ES][i][1];
|
||||||
|
float eri = cal_data[ETERM_ER][i][1] + s11mr * cal_data[ETERM_ES][i][1] + s11mi * cal_data[ETERM_ES][i][0];
|
||||||
|
float sq = err*err + eri*eri;
|
||||||
|
float s11ar = (s11mr * err + s11mi * eri) / sq;
|
||||||
|
float s11ai = (s11mi * err - s11mr * eri) / sq;
|
||||||
|
measured[0][i][0] = s11ar;
|
||||||
|
measured[0][i][1] = s11ai;
|
||||||
|
|
||||||
|
// CAUTION: Et is inversed for efficiency
|
||||||
|
// S21m' = S21m - Ex
|
||||||
|
// S21a = S21m' (1-EsS11a)Et
|
||||||
|
float s21mr = measured[1][i][0] - cal_data[ETERM_EX][i][0];
|
||||||
|
float s21mi = measured[1][i][1] - cal_data[ETERM_EX][i][1];
|
||||||
|
float esr = 1 - (cal_data[ETERM_ES][i][0] * s11ar - cal_data[ETERM_ES][i][1] * s11ai);
|
||||||
|
float esi = - (cal_data[ETERM_ES][i][1] * s11ar + cal_data[ETERM_ES][i][0] * s11ai);
|
||||||
|
float etr = esr * cal_data[ETERM_ET][i][0] - esi * cal_data[ETERM_ET][i][1];
|
||||||
|
float eti = esr * cal_data[ETERM_ET][i][1] + esi * cal_data[ETERM_ET][i][0];
|
||||||
|
float s21ar = s21mr * etr - s21mi * eti;
|
||||||
|
float s21ai = s21mi * etr + s21mr * eti;
|
||||||
|
measured[1][i][0] = s21ar;
|
||||||
|
measured[1][i][1] = s21ai;
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
cal_collect(int type)
|
cal_collect(int type)
|
||||||
{
|
{
|
||||||
|
|
@ -1567,7 +1606,7 @@ int main(void)
|
||||||
if (config.default_loadcal >= 0)
|
if (config.default_loadcal >= 0)
|
||||||
caldata_recall(config.default_loadcal);
|
caldata_recall(config.default_loadcal);
|
||||||
|
|
||||||
redraw();
|
redraw_frame();
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* I2S Initialize
|
* I2S Initialize
|
||||||
|
|
|
||||||
18
nanovna.h
18
nanovna.h
|
|
@ -205,10 +205,10 @@ typedef struct {
|
||||||
|
|
||||||
void plot_init(void);
|
void plot_init(void);
|
||||||
void update_grid(void);
|
void update_grid(void);
|
||||||
void clear_screen(void);
|
void request_to_redraw_grid(void);
|
||||||
void redraw(void);
|
void redraw_frame(void);
|
||||||
void redraw_all(void);
|
//void redraw_all(void);
|
||||||
void force_draw_cells(void);
|
void request_to_draw_cells_behind_menu(void);
|
||||||
void redraw_marker(int marker, int update_info);
|
void redraw_marker(int marker, int update_info);
|
||||||
void trace_get_info(int t, char *buf, int len);
|
void trace_get_info(int t, char *buf, int len);
|
||||||
void plot_into_index(float measured[2][101][2]);
|
void plot_into_index(float measured[2][101][2]);
|
||||||
|
|
@ -222,6 +222,8 @@ void markmap_all_markers(void);
|
||||||
void marker_position(int m, int t, int *x, int *y);
|
void marker_position(int m, int t, int *x, int *y);
|
||||||
int search_nearest_index(int x, int y, int t);
|
int search_nearest_index(int x, int y, int t);
|
||||||
|
|
||||||
|
extern int8_t redraw_requested;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* ili9341.c
|
* ili9341.c
|
||||||
*/
|
*/
|
||||||
|
|
@ -301,6 +303,14 @@ void clear_all_config_prop_data(void);
|
||||||
/*
|
/*
|
||||||
* ui.c
|
* ui.c
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
typedef struct {
|
||||||
|
int digit; /* 0~5 */
|
||||||
|
int current_trace; /* 0..3 */
|
||||||
|
} uistat_t;
|
||||||
|
|
||||||
|
extern uistat_t uistat;
|
||||||
|
|
||||||
void ui_init(void);
|
void ui_init(void);
|
||||||
void ui_show(void);
|
void ui_show(void);
|
||||||
void ui_hide(void);
|
void ui_hide(void);
|
||||||
|
|
|
||||||
57
plot.c
57
plot.c
|
|
@ -627,22 +627,18 @@ trace_get_info(int t, char *buf, int len)
|
||||||
const char *type = trc_type_name[trace[t].type];
|
const char *type = trc_type_name[trace[t].type];
|
||||||
switch (trace[t].type) {
|
switch (trace[t].type) {
|
||||||
case TRC_LOGMAG:
|
case TRC_LOGMAG:
|
||||||
chsnprintf(buf, len, "CH%d %s %ddB/",
|
chsnprintf(buf, len, "%s %ddB/", type, (int)(trace[t].scale*10));
|
||||||
trace[t].channel, type, (int)(trace[t].scale*10));
|
|
||||||
break;
|
break;
|
||||||
case TRC_PHASE:
|
case TRC_PHASE:
|
||||||
chsnprintf(buf, len, "CH%d %s %d" S_DEGREE "/",
|
chsnprintf(buf, len, "%s %d" S_DEGREE "/", type, (int)(trace[t].scale*90));
|
||||||
trace[t].channel, type, (int)(trace[t].scale*90));
|
|
||||||
break;
|
break;
|
||||||
case TRC_SMITH:
|
case TRC_SMITH:
|
||||||
//case TRC_ADMIT:
|
//case TRC_ADMIT:
|
||||||
case TRC_POLAR:
|
case TRC_POLAR:
|
||||||
chsnprintf(buf, len, "CH%d %s %.1fFS",
|
chsnprintf(buf, len, "%s %.1fFS", type, trace[t].scale);
|
||||||
trace[t].channel, type, trace[t].scale);
|
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
chsnprintf(buf, len, "CH%d %s %.1f/",
|
chsnprintf(buf, len, "%s %.1f/", type, trace[t].scale);
|
||||||
trace[t].channel, type, trace[t].scale);
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -1193,17 +1189,19 @@ redraw_marker(int marker, int update_info)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
force_draw_cells(void)
|
request_to_draw_cells_behind_menu(void)
|
||||||
{
|
{
|
||||||
int n, m;
|
int n, m;
|
||||||
for (m = 7; m <= 9; m++)
|
for (m = 7; m <= 9; m++)
|
||||||
for (n = 0; n < (area_height+CELLHEIGHT-1) / CELLHEIGHT; n++)
|
for (n = 0; n < (area_height+CELLHEIGHT-1) / CELLHEIGHT; n++)
|
||||||
draw_cell(m, n);
|
//draw_cell(m, n);
|
||||||
|
mark_map(m, n);
|
||||||
|
redraw_requested = TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
cell_drawchar_5x7(int w, int h, uint8_t ch, int x, int y, uint16_t fg)
|
cell_drawchar_5x7(int w, int h, uint8_t ch, int x, int y, uint16_t fg, int invert)
|
||||||
{
|
{
|
||||||
uint16_t bits;
|
uint16_t bits;
|
||||||
int c, r;
|
int c, r;
|
||||||
|
|
@ -1213,6 +1211,8 @@ cell_drawchar_5x7(int w, int h, uint8_t ch, int x, int y, uint16_t fg)
|
||||||
if ((y + c) < 0 || (y + c) >= h)
|
if ((y + c) < 0 || (y + c) >= h)
|
||||||
continue;
|
continue;
|
||||||
bits = x5x7_bits[(ch * 7) + c];
|
bits = x5x7_bits[(ch * 7) + c];
|
||||||
|
if (invert)
|
||||||
|
bits = ~bits;
|
||||||
for (r = 0; r < 5; r++) {
|
for (r = 0; r < 5; r++) {
|
||||||
if ((x+r) >= 0 && (x+r) < w && (0x8000 & bits))
|
if ((x+r) >= 0 && (x+r) < w && (0x8000 & bits))
|
||||||
spi_buffer[(y+c)*w + (x+r)] = fg;
|
spi_buffer[(y+c)*w + (x+r)] = fg;
|
||||||
|
|
@ -1225,7 +1225,17 @@ void
|
||||||
cell_drawstring_5x7(int w, int h, char *str, int x, int y, uint16_t fg)
|
cell_drawstring_5x7(int w, int h, char *str, int x, int y, uint16_t fg)
|
||||||
{
|
{
|
||||||
while (*str) {
|
while (*str) {
|
||||||
cell_drawchar_5x7(w, h, *str, x, y, fg);
|
cell_drawchar_5x7(w, h, *str, x, y, fg, FALSE);
|
||||||
|
x += 5;
|
||||||
|
str++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
cell_drawstring_invert_5x7(int w, int h, char *str, int x, int y, uint16_t fg, int invert)
|
||||||
|
{
|
||||||
|
while (*str) {
|
||||||
|
cell_drawchar_5x7(w, h, *str, x, y, fg, invert);
|
||||||
x += 5;
|
x += 5;
|
||||||
str++;
|
str++;
|
||||||
}
|
}
|
||||||
|
|
@ -1249,14 +1259,18 @@ cell_draw_marker_info(int m, int n, int w, int h)
|
||||||
int ypos = 1 + (j/2)*7;
|
int ypos = 1 + (j/2)*7;
|
||||||
xpos -= m * CELLWIDTH -CELLOFFSETX;
|
xpos -= m * CELLWIDTH -CELLOFFSETX;
|
||||||
ypos -= n * CELLHEIGHT;
|
ypos -= n * CELLHEIGHT;
|
||||||
|
chsnprintf(buf, sizeof buf, "CH%d", trace[t].channel);
|
||||||
|
cell_drawstring_invert_5x7(w, h, buf, xpos, ypos, config.trace_color[t], t == uistat.current_trace);
|
||||||
|
xpos += 20;
|
||||||
trace_get_info(t, buf, sizeof buf);
|
trace_get_info(t, buf, sizeof buf);
|
||||||
cell_drawstring_5x7(w, h, buf, xpos, ypos, config.trace_color[t]);
|
cell_drawstring_5x7(w, h, buf, xpos, ypos, config.trace_color[t]);
|
||||||
xpos += 84;
|
xpos += 64;
|
||||||
trace_get_value_string(t, buf, sizeof buf, measured[trace[t].channel][idx], frequencies[idx]);
|
trace_get_value_string(t, buf, sizeof buf, measured[trace[t].channel][idx], frequencies[idx]);
|
||||||
cell_drawstring_5x7(w, h, buf, xpos, ypos, config.trace_color[t]);
|
cell_drawstring_5x7(w, h, buf, xpos, ypos, config.trace_color[t]);
|
||||||
j++;
|
j++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// draw marker frequency
|
||||||
int xpos = 192;
|
int xpos = 192;
|
||||||
int ypos = 1 + (j/2)*7;
|
int ypos = 1 + (j/2)*7;
|
||||||
xpos -= m * CELLWIDTH -CELLOFFSETX;
|
xpos -= m * CELLWIDTH -CELLOFFSETX;
|
||||||
|
|
@ -1267,6 +1281,7 @@ cell_draw_marker_info(int m, int n, int w, int h)
|
||||||
frequency_string(buf, sizeof buf, frequencies[idx]);
|
frequency_string(buf, sizeof buf, frequencies[idx]);
|
||||||
cell_drawstring_5x7(w, h, buf, xpos, ypos, 0xffff);
|
cell_drawstring_5x7(w, h, buf, xpos, ypos, 0xffff);
|
||||||
|
|
||||||
|
// draw marker delta
|
||||||
if (active_marker != previous_marker && markers[previous_marker].enabled) {
|
if (active_marker != previous_marker && markers[previous_marker].enabled) {
|
||||||
int idx0 = markers[previous_marker].index;
|
int idx0 = markers[previous_marker].index;
|
||||||
xpos = 192;
|
xpos = 192;
|
||||||
|
|
@ -1311,18 +1326,22 @@ draw_frequencies(void)
|
||||||
int stop = frequency1;
|
int stop = frequency1;
|
||||||
strcpy(buf, "START ");
|
strcpy(buf, "START ");
|
||||||
frequency_string(buf+6, 24-6, start);
|
frequency_string(buf+6, 24-6, start);
|
||||||
|
strcat(buf, " ");
|
||||||
ili9341_drawstring_5x7(buf, OFFSETX, 233, 0xffff, 0x0000);
|
ili9341_drawstring_5x7(buf, OFFSETX, 233, 0xffff, 0x0000);
|
||||||
strcpy(buf, "STOP ");
|
strcpy(buf, "STOP ");
|
||||||
frequency_string(buf+5, 24-5, stop);
|
frequency_string(buf+5, 24-5, stop);
|
||||||
|
strcat(buf, " ");
|
||||||
ili9341_drawstring_5x7(buf, 205, 233, 0xffff, 0x0000);
|
ili9341_drawstring_5x7(buf, 205, 233, 0xffff, 0x0000);
|
||||||
} else if (frequency1 < 0) {
|
} else if (frequency1 < 0) {
|
||||||
int fcenter = frequency0;
|
int fcenter = frequency0;
|
||||||
int fspan = -frequency1;
|
int fspan = -frequency1;
|
||||||
strcpy(buf, "CENTER ");
|
strcpy(buf, "CENTER ");
|
||||||
frequency_string(buf+7, 24-7, fcenter);
|
frequency_string(buf+7, 24-7, fcenter);
|
||||||
|
strcat(buf, " ");
|
||||||
ili9341_drawstring_5x7(buf, OFFSETX, 233, 0xffff, 0x0000);
|
ili9341_drawstring_5x7(buf, OFFSETX, 233, 0xffff, 0x0000);
|
||||||
strcpy(buf, "SPAN ");
|
strcpy(buf, "SPAN ");
|
||||||
frequency_string(buf+5, 24-5, fspan);
|
frequency_string(buf+5, 24-5, fspan);
|
||||||
|
strcat(buf, " ");
|
||||||
ili9341_drawstring_5x7(buf, 205, 233, 0xffff, 0x0000);
|
ili9341_drawstring_5x7(buf, 205, 233, 0xffff, 0x0000);
|
||||||
} else {
|
} else {
|
||||||
int fcenter = frequency0;
|
int fcenter = frequency0;
|
||||||
|
|
@ -1377,28 +1396,28 @@ draw_cal_status(void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
clear_screen(void)
|
request_to_redraw_grid(void)
|
||||||
{
|
{
|
||||||
ili9341_fill(0, 0, 320, 240, 0);
|
force_set_markmap();
|
||||||
|
redraw_requested = TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
redraw(void)
|
redraw_frame(void)
|
||||||
{
|
{
|
||||||
ili9341_fill(0, 0, 320, 240, 0);
|
ili9341_fill(0, 0, 320, 240, 0);
|
||||||
draw_frequencies();
|
draw_frequencies();
|
||||||
draw_cal_status();
|
draw_cal_status();
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
/*void
|
||||||
redraw_all(void)
|
redraw_all(void)
|
||||||
{
|
{
|
||||||
redraw();
|
redraw();
|
||||||
force_set_markmap();
|
force_set_markmap();
|
||||||
draw_all_cells();
|
draw_all_cells();
|
||||||
}
|
}*/
|
||||||
|
|
||||||
void
|
void
|
||||||
plot_init(void)
|
plot_init(void)
|
||||||
|
|
|
||||||
53
ui.c
53
ui.c
|
|
@ -25,10 +25,7 @@
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
||||||
|
|
||||||
struct {
|
uistat_t uistat;
|
||||||
int digit; /* 0~5 */
|
|
||||||
int current_trace; /* 0..3 */
|
|
||||||
} uistat;
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -466,6 +463,7 @@ menu_trace_cb(int item)
|
||||||
trace[item].enabled = TRUE;
|
trace[item].enabled = TRUE;
|
||||||
uistat.current_trace = item;
|
uistat.current_trace = item;
|
||||||
menu_move_back();
|
menu_move_back();
|
||||||
|
request_to_redraw_grid();
|
||||||
ui_mode_normal();
|
ui_mode_normal();
|
||||||
//redraw_all();
|
//redraw_all();
|
||||||
}
|
}
|
||||||
|
|
@ -492,6 +490,7 @@ menu_format_cb(int item)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
request_to_redraw_grid();
|
||||||
ui_mode_normal();
|
ui_mode_normal();
|
||||||
//redraw_all();
|
//redraw_all();
|
||||||
}
|
}
|
||||||
|
|
@ -508,6 +507,7 @@ menu_format2_cb(int item)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
request_to_redraw_grid();
|
||||||
ui_mode_normal();
|
ui_mode_normal();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -565,6 +565,7 @@ menu_trace_op_cb(int item)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
menu_move_back();
|
menu_move_back();
|
||||||
|
request_to_redraw_grid();
|
||||||
ui_mode_normal();
|
ui_mode_normal();
|
||||||
//redraw_all();
|
//redraw_all();
|
||||||
}
|
}
|
||||||
|
|
@ -596,29 +597,50 @@ menu_stimulus_cb(int item)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static int32_t
|
||||||
|
get_marker_frequency(int marker)
|
||||||
|
{
|
||||||
|
if (marker < 0 || marker >= 4)
|
||||||
|
return -1;
|
||||||
|
if (!markers[marker].enabled)
|
||||||
|
return -1;
|
||||||
|
return frequencies[markers[marker].index];
|
||||||
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
menu_marker_op_cb(int item)
|
menu_marker_op_cb(int item)
|
||||||
{
|
{
|
||||||
if (active_marker < 0)
|
int32_t freq = get_marker_frequency(active_marker);
|
||||||
return;
|
if (freq < 0)
|
||||||
int idx = markers[active_marker].index;
|
return; // no active marker
|
||||||
int32_t marker_freq = frequencies[idx];
|
|
||||||
|
|
||||||
switch (item) {
|
switch (item) {
|
||||||
case 1: /* MARKER->START */
|
case 1: /* MARKER->START */
|
||||||
set_sweep_frequency(ST_START, marker_freq);
|
set_sweep_frequency(ST_START, freq);
|
||||||
break;
|
break;
|
||||||
case 2: /* MARKER->STOP */
|
case 2: /* MARKER->STOP */
|
||||||
set_sweep_frequency(ST_STOP, marker_freq);
|
set_sweep_frequency(ST_STOP, freq);
|
||||||
break;
|
break;
|
||||||
case 3: /* MARKER->CENTER */
|
case 3: /* MARKER->CENTER */
|
||||||
set_sweep_frequency(ST_CENTER, marker_freq);
|
set_sweep_frequency(ST_CENTER, freq);
|
||||||
break;
|
break;
|
||||||
case 4: /* MARKER->SPAN */
|
case 4: /* MARKERS->SPAN */
|
||||||
{
|
{
|
||||||
int32_t span = (frequency0 - marker_freq) * 2;
|
int32_t freq2 = get_marker_frequency(previous_marker);
|
||||||
|
if (freq2 < 0)
|
||||||
|
return;
|
||||||
|
if (freq > freq2) {
|
||||||
|
freq2 = freq;
|
||||||
|
freq = get_marker_frequency(previous_marker);
|
||||||
|
}
|
||||||
|
set_sweep_frequency(ST_START, freq);
|
||||||
|
set_sweep_frequency(ST_STOP, freq2);
|
||||||
|
#if 0
|
||||||
|
int32_t span = (freq - freq2) * 2;
|
||||||
if (span < 0) span = -span;
|
if (span < 0) span = -span;
|
||||||
set_sweep_frequency(ST_SPAN, span);
|
set_sweep_frequency(ST_SPAN, span);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
@ -1139,7 +1161,7 @@ ui_mode_normal(void)
|
||||||
area_width = AREA_WIDTH_NORMAL;
|
area_width = AREA_WIDTH_NORMAL;
|
||||||
area_height = HEIGHT;
|
area_height = HEIGHT;
|
||||||
erase_menu_buttons();
|
erase_menu_buttons();
|
||||||
force_draw_cells();
|
request_to_draw_cells_behind_menu();
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
@ -1325,7 +1347,8 @@ ui_process_keypad(void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
clear_screen();
|
redraw_frame();
|
||||||
|
request_to_redraw_grid();
|
||||||
ui_mode_normal();
|
ui_mode_normal();
|
||||||
//redraw_all();
|
//redraw_all();
|
||||||
touch_start_watchdog();
|
touch_start_watchdog();
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue