pull/162/merge
PhysicistJohn 1 week ago committed by GitHub
commit 910f8a979a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -955,12 +955,7 @@ VNA_SHELL_FUNCTION(cmd_text)
{ {
if (argc!= 1) if (argc!= 1)
return; return;
char *p = argv[0]; ui_set_keypad_text(argv[0]);
char *t = kp_buf;
while (*p) {
*t++ = *p++;
}
*t = 0;
uistat.value = my_atof(kp_buf); uistat.value = my_atof(kp_buf);
uistat.freq_value = my_atoui(kp_buf); uistat.freq_value = my_atoui(kp_buf);
set_numeric_value(); set_numeric_value();

@ -1593,6 +1593,7 @@ extern const char * const averageText[];
extern uint8_t menu_current_level; extern uint8_t menu_current_level;
void menu_invoke(int item); void menu_invoke(int item);
extern char kp_buf[]; extern char kp_buf[];
void ui_set_keypad_text(const char *text);
void set_numeric_value(void); void set_numeric_value(void);
void ui_mode_normal(void); void ui_mode_normal(void);

@ -96,6 +96,12 @@ char kp_buf[NUMINPUT_LEN+2]; // !!!!!! WARNING size must be + 2 from NUMINPU
#else #else
char kp_buf[TXTINPUT_LEN+1]; // !!!!!! WARNING size must be + 2 from NUMINPUT_LEN or TXTINPUT_LEN + 1 char kp_buf[TXTINPUT_LEN+1]; // !!!!!! WARNING size must be + 2 from NUMINPUT_LEN or TXTINPUT_LEN + 1
#endif #endif
void ui_set_keypad_text(const char *text)
{
plot_printf(kp_buf, sizeof(kp_buf), "%s", text);
}
static uint8_t ui_mode = UI_NORMAL; static uint8_t ui_mode = UI_NORMAL;
static uint8_t keypad_mode; static uint8_t keypad_mode;
static char *kp_help_text = NULL; static char *kp_help_text = NULL;

Loading…
Cancel
Save

Powered by TurnKey Linux.