18
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-11-24 18:59:16 +01:00

Merge pull request #278 from MaSzyna-EU07/feat/shunt-lock-resistive

Field shunting locked at zero and on resistive positions (eu07/maszyna#402)
This commit is contained in:
2026-11-09 12:53:57 +00:00
committed by GitHub
4 changed files with 172 additions and 3 deletions

View File

@@ -1987,6 +1987,7 @@ class TMoverParameters
double MirrorVelClose{5.0};
bool MirrorForbidden{false}; /*czy jest pozwolenie na otworzenie lusterek (przycisk)*/
bool ScndS = false; /*Czy jest bocznikowanie na szeregowej*/
bool ScndCtrlResistiveLock{false}; // the shunt controller can't be moved, up or down, while the master controller is at zero or on a resistive position, and drops to 0 when the master controller gets there (ScndCtrlResistiveLock=Yes in Cntrl.)
bool SpeedCtrl = false; /*czy jest tempomat*/
speed_control SpeedCtrlUnit; /*parametry tempomatu*/
double SpeedCtrlButtons[10]{30, 40, 50, 60, 70, 80, 90, 100, 110, 120}; /*przyciski prędkości*/
@@ -2430,6 +2431,11 @@ class TMoverParameters
bool IncScndCtrl(int CtrlSpeed);
bool DecScndCtrl(int CtrlSpeed);
int GetVirtualScndPos() const;
// whether ScndCtrlResistiveLock keeps the shunt controller from being moved at the current master controller position
bool IsScndCtrlLockedByMainCtrl() const;
// ScndCtrlResistiveLock: the shunt controller drops to 0 once the master controller is at zero or on a resistive position, so it
// can't stay engaged there, locked in place (eu07/maszyna#402)
void ScndCtrlResistiveLockCheck();
bool IsScndCtrlNoPowerPos() const;
bool IsScndCtrlMaxPowerPos() const;