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

set the reset packet counter of the prog track to 0 every time the track is turned on

This commit is contained in:
Harald Barth
2022-04-30 23:24:51 +02:00
parent 43bac3f78e
commit 7a2fd90bfc
4 changed files with 9 additions and 0 deletions

View File

@@ -124,6 +124,8 @@ bool TrackManager::setTrackMode(byte trackToSet, TRACK_MODE mode, int16_t dcAddr
track[t]->setPower(POWERMODE::OFF);
trackMode[t]=TRACK_MODE_OFF;
}
} else {
track[trackToSet]->setResetCounterPointer(NULL); // only the prog track has this pointer set
}
trackMode[trackToSet]=mode;
trackDCAddr[trackToSet]=dcAddr;