Removed color red from status panel and added scan speed indicator

pull/4/head
erikkaashoek 6 years ago
parent 43da653076
commit a7c4558452

@ -1093,6 +1093,7 @@ search_index_range_x(int x1, int x2, index_t index[POINTS_COUNT], int *i0, int *
return TRUE; return TRUE;
} }
#if 0 // Not used as refpos is always at top of screen
#define REFERENCE_WIDTH 6 #define REFERENCE_WIDTH 6
#define REFERENCE_HEIGHT 5 #define REFERENCE_HEIGHT 5
@ -1124,6 +1125,7 @@ draw_refpos(int x, int y, int c)
} }
} }
} }
#endif
#define MARKER_WIDTH 7 #define MARKER_WIDTH 7
#define MARKER_HEIGHT 10 #define MARKER_HEIGHT 10

@ -870,7 +870,6 @@ void set_freq(int V, unsigned long freq)
delta = delta * 4 / 625; // = 156.25; delta = delta * 4 / 625; // = 156.25;
SI4432_Write_Byte(0x73, (uint8_t)(delta & 0xff)); SI4432_Write_Byte(0x73, (uint8_t)(delta & 0xff));
uint8_t reg = delta >> 8;
SI4432_Write_Byte(0x74, (uint8_t)((delta >> 8) & 0x03)); SI4432_Write_Byte(0x74, (uint8_t)((delta >> 8) & 0x03));
SI4432_offset_changed = true; SI4432_offset_changed = true;
old_freq[V] = freq; old_freq[V] = freq;
@ -2167,9 +2166,7 @@ void draw_cal_status(void)
} }
#endif #endif
// Sweep time // Sweep time
if (dirty) if (setting.step_delay)
color = BRIGHT_COLOR_RED;
else if (setting.step_delay)
color = BRIGHT_COLOR_GREEN; color = BRIGHT_COLOR_GREEN;
else else
color = DEFAULT_FG_COLOR; color = DEFAULT_FG_COLOR;
@ -2177,7 +2174,14 @@ void draw_cal_status(void)
ili9341_set_foreground(color); ili9341_set_foreground(color);
y += YSTEP + YSTEP/2 ; y += YSTEP + YSTEP/2 ;
ili9341_drawstring("Scan:", x, y);
buf[0] = ' ';
if (setting.step_delay == 1)
buf[0] = 'P';
if (setting.step_delay == 2)
buf[0] = 'F';
strcpy(&buf[1],"Scan:");
ili9341_drawstring(buf, x, y);
y += YSTEP; y += YSTEP;
uint32_t t = calc_min_sweep_time_us(); uint32_t t = calc_min_sweep_time_us();
@ -2189,7 +2193,7 @@ void draw_cal_status(void)
// Cal output // Cal output
if (setting.refer >= 0) { if (setting.refer >= 0) {
ili9341_set_foreground(BRIGHT_COLOR_RED); ili9341_set_foreground(BRIGHT_COLOR_GREEN);
y += YSTEP + YSTEP/2 ; y += YSTEP + YSTEP/2 ;
ili9341_drawstring("Ref:", x, y); ili9341_drawstring("Ref:", x, y);
@ -2201,7 +2205,7 @@ void draw_cal_status(void)
// Offset // Offset
if (setting.offset != 0.0) { if (setting.offset != 0.0) {
ili9341_set_foreground(BRIGHT_COLOR_RED); ili9341_set_foreground(BRIGHT_COLOR_GREEN);
y += YSTEP + YSTEP/2 ; y += YSTEP + YSTEP/2 ;
ili9341_drawstring("Amp:", x, y); ili9341_drawstring("Amp:", x, y);

Loading…
Cancel
Save

Powered by TurnKey Linux.