UnblockTrain

From Planimate Knowledge Base
Jump to: navigation, search

Routine operation "UnblockTrain" enables the modeller to trigger an unblock for all blocked trains or a specific train ID.

If ID is 0 then an unblock attempt is made for all trains.

If ID is set > 0 then an unblock attempt is made only for the specific item with the matching item ID.

The detailed way it works is as follows:

An unblock event gets posted to the FEC with the train ID to try.

When the event is processed, if the blocked train is still in the blocked train list, it and only it will get an unblock attempt.

This makes this operation safe even if the train already became unblocked (or even exitted the model) before the unblock message it processed.

This operation is useful where the modeller knows a state change in a track network can release trains.

If the train ID is known, then using it can avoid the platform unnecessarily testing all the blocked trains.

This will improve performance in networks with many blocked trains.