diff --git a/sa_cmd.c b/sa_cmd.c index 2470b10..2dc8200 100644 --- a/sa_cmd.c +++ b/sa_cmd.c @@ -1159,7 +1159,7 @@ VNA_SHELL_FUNCTION(cmd_q) { if (argc < 1) { usage: - usage_printf("q [s0..1|d0..18|a0..63|p0..4]\r\n"); + usage_printf("q [s0..1|d-1,0..18|a0..63|p0..4]\r\n"); test_output=false; test_output_switch = false; test_output_drive = 0; diff --git a/sa_core.c b/sa_core.c index 79df0dc..4e64378 100644 --- a/sa_core.c +++ b/sa_core.c @@ -190,12 +190,13 @@ void set_output_path(freq_t f, float level) if (test_output) { signal_path = test_path; setting.mixer_output = (signal_path == PATH_ULTRA); - setting.atten_step = test_output_switch; - set_output_drive(test_output_drive); - PE4302_Write_Byte(test_output_attenuate); - goto set_path; - } - if (setting.mute) + if (test_output_drive >=0) { + setting.atten_step = test_output_switch; + set_output_drive(test_output_drive); + PE4302_Write_Byte(test_output_attenuate); + goto set_path; + } + } else if (setting.mute) signal_path = PATH_OFF; else if (MODE_HIGH(setting.mode)) signal_path = PATH_HIGH;