Page tree

Versions Compared


  • This line was added.
  • This line was removed.
  • Formatting was changed.


Field nameContent typeValue rangeNumber of valuesDescription

The speed each track is set at.

TrackContactsbooleanfalse-true96Whether or not a contact is triggered. Contacts on the same track are consecutive, for instance the contacts on track 0 are represented by indexes 0 and 1 in this array.



30Whether a given directional switch is set to straight or branch.

The track each train is currently on.

Bellbooleanfalse-true1Whether the bell is ringing or not.
Gate0booleanfalse-true1Whether gate 0 is raised or not.
Gate1booleanfalse-true1Whether gate 1 is raised or not.

Controller Input

The controller accepts the following input format read from a JSON file. The JSON file is called input.json and is found in $XDG_CONFIG_HOME/railway if XDG_CONFIG_HOME is set or from $HOME/.config/railway if it isn't.

Field nameContent typeValue rangeNumber of valuesDescription
Actionint0-MAXINT10, 0-47,0-47,0-142Contains the description of a new train action in the format: [ id, start, destination , reverse flag ]