Changed range to new values.

This commit is contained in:
jupfi 2023-08-18 14:58:13 +02:00
parent cd22f0c8ad
commit 1ae4a52fd1
3 changed files with 15 additions and 6 deletions

View file

@ -44,7 +44,7 @@ const FrequencyRange RANGE_70_125MHZ =
100000000U, 100000000U,
FG_120MHZ, FG_120MHZ,
34400U, 34400U,
48500U, 60500U,
}; };
const FrequencyRange RANGE_125_180MHZ = const FrequencyRange RANGE_125_180MHZ =

View file

@ -27,7 +27,8 @@ void ControlSwitch::execute(String input_line)
} }
else if (switch_to == switch_state) else if (switch_to == switch_state)
{ {
result = "Already switched to " + String(switch_to); String active_pathway = (switch_state == PRE_AMP) ? "preamp" : "atm system";
result = "Already switched to " + String(active_pathway);
} }
else else
{ {

View file

@ -1,13 +1,21 @@
#include "Utilities.h" #include "Utilities.h"
#include "Homing.h" #include "Homing.h"
void Homing::execute(String input_line) { void Homing::execute(String input_line)
{
printInfo("Homing..."); printInfo("Homing...");
tuner.STEPPER.setCurrentPosition(homeStepper(tuner)); tuner.STEPPER.setCurrentPosition(homeStepper(tuner));
matcher.STEPPER.setCurrentPosition(homeStepper(matcher)); matcher.STEPPER.setCurrentPosition(homeStepper(matcher));
tuner.STEPPER.moveTo(RANGE_70_125MHZ.TUNING_CENTER_POSITION);
tuner.STEPPER.runToPosition();
matcher.STEPPER.moveTo(RANGE_70_125MHZ.MATCHING_CENTER_POSITION);
matcher.STEPPER.runToPosition();
} }
void Homing::printResult() { void Homing::printResult()
{
printInfo("Resonance frequency after homing:"); printInfo("Resonance frequency after homing:");
uint32_t startf = 35000000U; uint32_t startf = 35000000U;
uint32_t stopf = 110000000U; uint32_t stopf = 110000000U;
@ -18,10 +26,10 @@ void Homing::printResult() {
printInfo("Homing finished"); printInfo("Homing finished");
} }
void Homing::printHelp() { void Homing::printHelp()
{
Serial.println("Homing command"); Serial.println("Homing command");
Serial.println("Syntax: h"); Serial.println("Syntax: h");
Serial.println("Example: h"); Serial.println("Example: h");
Serial.println("This will home the tuner and matcher"); Serial.println("This will home the tuner and matcher");
} }