mirror of
https://github.com/ttrftech/NanoVNA.git
synced 2026-04-09 00:13:59 +00:00
feat: change the operations to select lever mode
This commit is contained in:
parent
fb3c9cf82f
commit
93d1233d8b
4 changed files with 68 additions and 18 deletions
12
plot.c
12
plot.c
|
|
@ -1467,7 +1467,9 @@ draw_all_cells(bool flush_markmap)
|
|||
void
|
||||
draw_all(bool flush)
|
||||
{
|
||||
if (redraw_request & REDRAW_CELLS)
|
||||
if (redraw_request & REDRAW_MARKER)
|
||||
markmap_upperarea();
|
||||
if (redraw_request & (REDRAW_CELLS | REDRAW_MARKER))
|
||||
draw_all_cells(flush);
|
||||
if (redraw_request & REDRAW_FREQUENCY)
|
||||
draw_frequencies();
|
||||
|
|
@ -1681,12 +1683,12 @@ draw_frequencies(void)
|
|||
char buf1[32];
|
||||
char buf2[32];buf2[0]=0;
|
||||
if ((domain_mode & DOMAIN_MODE) == DOMAIN_FREQ) {
|
||||
if (frequency0 < frequency1) {
|
||||
if (FREQ_IS_STARTSTOP()) {
|
||||
chsnprintf(buf1, sizeof(buf1), " START %qHz", frequency0);
|
||||
chsnprintf(buf2, sizeof(buf2), " STOP %qHz", frequency1);
|
||||
} else if (frequency0 > frequency1) {
|
||||
chsnprintf(buf1, sizeof(buf1), " CENTER %qHz", frequency0/2 + frequency1/2);
|
||||
chsnprintf(buf2, sizeof(buf2), " SPAN %qHz", frequency0 - frequency1);
|
||||
} else if (FREQ_IS_CENTERSPAN()) {
|
||||
chsnprintf(buf1, sizeof(buf1), " CENTER %qHz", FREQ_CENTER());
|
||||
chsnprintf(buf2, sizeof(buf2), " SPAN %qHz", FREQ_SPAN());
|
||||
} else {
|
||||
chsnprintf(buf1, sizeof(buf1), " CW %qHz", frequency0);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue