1
0
mirror of https://github.com/DCC-EX/CommandStation-EX.git synced 2025-07-28 09:53:45 +02:00

Withrottle in use change

This commit is contained in:
Asbelos
2020-08-14 12:26:14 +01:00
parent 7815fdcad8
commit a217031f24
4 changed files with 22 additions and 19 deletions

View File

@@ -95,15 +95,6 @@ bool DCC::getThrottleDirection(int cab) {
return (speedTable[reg].speedCode & 0x80) !=0;
}
bool DCC::isThrottleInUse(int locoId) {
// return true if this loco address is already in table, false otherwise
int reg;
for (reg = 0; reg < MAX_LOCOS; reg++) {
if (speedTable[reg].loco == locoId) return true;
}
return false;
}
// Set function to value on or off
void DCC::setFn( int cab, byte functionNumber, bool on) {
if (cab<=0 || functionNumber>28) return;