549 lines
29 KiB
Plaintext
549 lines
29 KiB
Plaintext
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta name="generator" content="HTML Tidy for HTML5 for Apple macOS version 5.8.0">
|
|
<!-- Copyright Bob Jacobsen 2008 -->
|
|
|
|
<title>JMRI: Signaling introduction</title>
|
|
<meta name="Author" content="Bob Jacobsen">
|
|
<meta name="Author" content="Egbert Broerse">
|
|
<meta name="Author" content="B. Milhaupt">
|
|
<meta name="Date.Modified" content="20200106"><!--#include virtual="/help/en/parts/Style.shtml" -->
|
|
</head>
|
|
<body>
|
|
<!--#include virtual="/help/en/parts/Header.shtml" -->
|
|
|
|
<div id="mBody">
|
|
<!--#include virtual="Sidebar.shtml" -->
|
|
|
|
<div id="mainContent">
|
|
<!-- Page Body -->
|
|
|
|
<h1>JMRI: Signaling</h1>
|
|
|
|
<p>This page introduces Signaling, lists the JMRI Signaling Tools and points to more advanced
|
|
methods.</p>
|
|
|
|
<p>Modeling railroad signaling on a layout can be done in many different ways, ranging from
|
|
simple "stoplights" to a complete emulation of a particular prototype's signaling rules. JMRI
|
|
provides a combination of tools to implement Signaling. JMRI supports <a href=
|
|
"AspectSignaling.shtml">prototypical signaling</a> based on signal <a href=
|
|
"#aspect">Aspects</a> and <a href="#appearance">Appearances</a> along with CTC dispatching
|
|
and interlocking, without requiring the user to write any script or Java code.</p>
|
|
|
|
<ul>
|
|
<li>
|
|
<a href="#terms">Signaling Vocabulary</a>
|
|
</li>
|
|
|
|
<li>
|
|
<a href="#signaling">Prototype Railroad Signaling</a>
|
|
</li>
|
|
|
|
<li>
|
|
<a href="#tools">JMRI Signaling Tools</a>
|
|
</li>
|
|
|
|
<li>
|
|
<a href="#advanced">Advanced Signaling</a>
|
|
</li>
|
|
</ul>
|
|
|
|
<h2 id="terms">Signaling Vocabulary</h2>
|
|
|
|
<h3>Prototype Railroad Signaling terms</h3>
|
|
<a href="https://commons.wikimedia.org/wiki/File:CSX_River_Sub_Kingston_CP_90.jpg"><img src=
|
|
"images/132px-CSX_River_Sub_Kingston_CP_90.jpg" width="132" height="240" class="floatRight"
|
|
alt="kingston sub"></a>
|
|
<!-- With some very useful information from the JMRI developers structure site -->
|
|
|
|
<ul>
|
|
<li>
|
|
<a id="head"><strong>Signal Head</strong></a> or <strong>Signal Arm</strong> Each
|
|
individual signal unit on a lit or semaphore Signal Mast. It shows exactly one
|
|
Appearance, generally a color (though not always, e.g. semaphores).
|
|
</li>
|
|
|
|
<li>
|
|
<strong>Light</strong> The individual lamp in a signal. A light may indicate multiple
|
|
<a href="#aspect">Aspects</a> if it changes color like in a Searchlight signal, or it may
|
|
take multiple lights to indicate a single <a href="#aspect">Aspect</a>, for example in
|
|
Position Light Signals.
|
|
</li>
|
|
|
|
<li><strong>Marker</strong> A Signal Head or Arm that does not change color or
|
|
position.</li>
|
|
|
|
<li><strong>Signal</strong> The object that conveys an Indication via a specific pattern of
|
|
its visible parts. It can be as simple as a sign, saying "start CTC"; that conveys a
|
|
particular indication and invokes a rule. Usually we're referring to lit or movable
|
|
Signals, though, which can show more than one Indication. The Signal might have one light
|
|
and use different colors to convey different Indications, or it needs more than one set of
|
|
lights to display a wider range of Aspects to fit the location.</li>
|
|
|
|
<li><strong>Signal Mast</strong> The pole that mounts one or more Signal Heads or Arms and
|
|
(usually) controls one individual track. Also used to refer to an entire signal made up of
|
|
one or more Signal Heads. Dwarf Signals are also considered Signal Masts.</li>
|
|
|
|
<li>
|
|
<a id="appearance"><strong>Appearance</strong></a> One of a series of allowed options for
|
|
a <a href="#head">Signal Head</a> or Signal Arm, e.g. Red, Green, Raised.
|
|
</li>
|
|
|
|
<li>
|
|
<a id="aspect"><strong>Aspect</strong></a> One of a series of allowed options for the
|
|
visual pattern of a Signal Mast using one or more Signal Heads or Arms to convey a speed
|
|
or route <a href="#indication">Indication</a>. Different Signal Mast types can use
|
|
different Aspects for a specific Indication, but a particular Signal Mast type always
|
|
conveys a particular Indication via just one Aspect. For example, to convey "You can run
|
|
at full speed" - an Indication (Rule 281, "Clear") - one signal might display a single
|
|
green light, another might show a green over red, and a third might have an upward
|
|
semaphore. Those are all different Aspects showing the same Indication. As all these
|
|
different Aspects are assigned the same descriptive name, e.g. "Approach", when you think
|
|
of these Aspects as "Approach on a triple searchlight signal" and "Approach on a single
|
|
semaphore" and the difference is evident.
|
|
</li>
|
|
|
|
<li>
|
|
<a id="indication"><strong>Indication</strong></a> On (most) western US railroads,
|
|
"Indication" refers to the message that a Signal is sending. It generally has a name,
|
|
like "Clear" or "Approach", but officially it's a railroad Rule (like 281 or 285) that
|
|
the train must obey when governed by that Signal. So Indication is the <em>meaning</em> a
|
|
signal conveys to the engineer, say the full instruction for a signal Aspect, e.g.
|
|
"Proceed preparing to stop at next signal. Train exceeding medium speed must at once
|
|
reduce to that speed." (for the "Approach" Aspect according to the AAR 1946 Rule Book).
|
|
</li>
|
|
|
|
<li><strong>Distant Signal</strong> The signal you are controlling is called a Distant
|
|
Signal if it is programmed to show the same or a more restrictive Aspect as the next signal
|
|
in the direction and route of travel.</li>
|
|
|
|
<li>
|
|
<strong>Dark Territory</strong> Section of running track not controlled by signals.
|
|
<a href="https://en.wikipedia.org/wiki/Dark_territory">Dark Territory</a> is governed by
|
|
other methods like Timetable and Train Order (TT & TO) Operation, Direct Traffic Control
|
|
or Track Warrants.
|
|
</li>
|
|
</ul>
|
|
|
|
<p>Different railroads have different Rules to operate rail traffic, using different terms.
|
|
In their respective Rule Books, they use different Aspects for rules of the same name. And
|
|
some will have different Appearances to make up those Aspects (e.g. semaphore vs. single
|
|
lamps vs. color-position signals vs. position light signals vs. cab signals vs ...)<br>
|
|
Picture on the right: a CSX Searchlight Signal Mast with 2 Signal Heads, showing a "red over
|
|
red" Aspect, meaning the "Stop" Indication.</p>
|
|
|
|
<h3>JMRI specific Signaling terms</h3>
|
|
|
|
<ul>
|
|
<li>
|
|
<strong>Virtual</strong> Virtual signals are JMRI internal signals with no actual
|
|
hardware attached. Virtual Signals may represent theoretical Aspects at buffer stops or
|
|
in staging that are used by prior signals. They may also be useful with <a href=
|
|
"../../../package/jmri/jmrit/beantable/SignalMastRepeater.shtml">Signal Mast
|
|
Repeaters</a>.<br>
|
|
|
|
<ul>
|
|
<li>When using JMRI Signal Heads, the list of signal head types includes the option
|
|
"Virtual".</li>
|
|
|
|
<li>When using JMRI Signal Masts, the list of "Mast Driver" types includes a "Virtual
|
|
Mast" driver type.</li>
|
|
</ul>
|
|
</li>
|
|
|
|
<li><strong>Protected Sensor</strong> The next block occupancy sensor(s) following the
|
|
signal you are controlling in the direction and route of travel. The "protection" is to
|
|
prevent a train from entering an occupied block without warning.</li>
|
|
|
|
<li><strong>Protected Signal</strong> The next signal after the one you are controlling in
|
|
the direction and route of travel. The "protection" is to prevent a train from approaching
|
|
a stop signal without sufficient warning to allow it to be stopped short of reaching the
|
|
"protected" signal.</li>
|
|
|
|
<li>
|
|
<strong>Signaling System</strong> A set of icons, definition files and rules following
|
|
either a prototype Rule Book or a simplified set of rules (see <a href=
|
|
"AspectSignaling.shtml#systems">this list</a>).
|
|
</li>
|
|
|
|
<li>
|
|
<strong>System Name</strong> The name of a JMRI object identifying either a virtual
|
|
(Internal) or physical piece of hardware being used, e.g. an output on a decoder to
|
|
control a signal. The System Name must follow certain <a href=
|
|
"../../doc/Technical/Names.shtml">Naming Rules</a> to be correctly interpreted by JMRI,
|
|
and the name will vary depending on your hardware so it must match your DCC system.
|
|
</li>
|
|
</ul>
|
|
|
|
<h2 id="signaling">Prototype Railroad Signaling</h2>
|
|
|
|
<p>Across the world railroads have developed a wide range of signaling hardware such as Flags
|
|
(not supported in JMRI), Semaphores, Position Light Signals and Color Light Signals.
|
|
Different physical signals may show the same "Indication" using different combinations of
|
|
lights, semaphore positions, and/or placards; these patterns of lights are called "Aspects".
|
|
For example, the "Stop" Aspect will be a single red light on a signal mast with only one
|
|
lamp, red over red lamps for a signal mast with two lamps, etc. To learn the rules of the
|
|
railroad you model is part of the hobby but JMRI helps by providing more than 20 prototypical
|
|
signaling systems from different countries to choose from. Still, it's up to the engineer to
|
|
interpret the Signal Aspects displayed and adjust the throttle...</p>
|
|
|
|
<p>Much of basic <a href=
|
|
"https://en.wikipedia.org/wiki/Automatic_block_signaling#Automatic_traffic_control">Automatic
|
|
Block Signaling</a> (ABS) can be boiled down to "a Signal goes Red when a train can't safely
|
|
enter the block it protects; it goes Yellow when the block following the protected block
|
|
can't be entered". Although that's a simplification, it can serve as a good starting point
|
|
for understanding signaling logic. More modern signaling systems are <a href=
|
|
"https://en.wikipedia.org/wiki/Automatic_block_signaling#Automatic_traffic_control">Absolute
|
|
Permissive Block</a> (APB) signaling used by many western US railroads and <a href=
|
|
"https://en.wikipedia.org/wiki/Centralized_traffic_control">Centralized Traffic Control</a>
|
|
(CTC) remotely operated from large switchboards.</p>
|
|
|
|
<h3>Standard CTC nomenclature</h3>
|
|
|
|
<h4>Union Switch & Signal Company (US&S)</h4>
|
|
|
|
<ul>
|
|
<li>Signals are identified by EVEN numbers with movement direction as depicted on the panel
|
|
(R - right, L - left)</li>
|
|
|
|
<li>Switches are identified as ODD numbers</li>
|
|
</ul>
|
|
|
|
<p>Example #1: Signals at a controlled switch with single track approaching from the left to
|
|
two tracks moving to right - 2R (facing point), 2L (main route), 2LA (diverging route). 2LA
|
|
would be shown as 2L on the panel to correspond with Signal Lever 2. Cardinal directions
|
|
might also be used (N, S, E, W) at a diamond for the opposing route. Switches are N (normal)
|
|
or R (reverse).<br>
|
|
Example #2: Dennis Drury's CTC signals get even numbers with a directional modifier such as E
|
|
50 W or E 52 W. The intermediate block signals may be numbered based on milepost locations
|
|
such as 322.2 and 322.3.</p>
|
|
|
|
<h4>General Railroad Signal (GRS)</h4>
|
|
|
|
<ul>
|
|
<li>Signals get ODD numbers</li>
|
|
|
|
<li>Switches get EVEN numbers (as opposed to US&S!)</li>
|
|
|
|
<li>Same R - right, L - left scheme, though</li>
|
|
</ul>
|
|
|
|
<p>Thanks to Jim Duncan, who adds: There are always exceptions! Any labeling must be
|
|
consistent, easy to understand, and have absolutely no possibility of being confused with any
|
|
other signal, switch or lever.</p>
|
|
|
|
<h3>Further reading</h3>
|
|
|
|
<p>There are a lot of excellent sources of information on prototype signaling, including:</p>
|
|
|
|
<ul>
|
|
<li>The <a href="https://en.wikipedia.org/wiki/Railway_signal">Wikipedia Signaling page</a>
|
|
</li>
|
|
|
|
<li>
|
|
<a href="http://www.mikeroque.com/railroad-signals/">Understanding Railroad Signals</a>
|
|
by A.A. Krug
|
|
</li>
|
|
|
|
<li>
|
|
<a href="http://www.lundsten.dk/us_signaling/">North American Signaling</a> is a
|
|
comprehensive website by Carsten S. Lundsten
|
|
</li>
|
|
|
|
<li>The <a href="http://www.railway-technical.com/signalling/">Railway Technical Index
|
|
Signaling chapter</a> provides lots of information from all over the world.
|
|
</li>
|
|
|
|
<li>
|
|
<a href="https://catalog.hathitrust.org/Record/002567896">Railroad operation and railway
|
|
signaling</a> by Edmund J. Phillips, Jr., Simmons-Boardman Publ., 1942
|
|
</li>
|
|
|
|
<li>John Armstrong's book <em>The Railroad: What It Is, What It Does</em>, Simmons-Boardman
|
|
Books Inc., 1990</li>
|
|
|
|
<li>Dr. Bruce Chubb's <em>Computer/Model Railroad Interface (C/MRI) User Manual rev
|
|
3.0</em> has signaling information in chapter 12.</li>
|
|
|
|
<li>US prototype AAR rules section 2 (<a href=
|
|
"http://www.rrsignalpix.com/AAR_2_sec.pdf">http://www.rrsignalpix.com/AAR_2_sec.pdf</a>)
|
|
provides a starting point for understanding US signaling rules.
|
|
</li>
|
|
|
|
<li>
|
|
<a href="https://railroadsignals.us/basics/nomenclature.htm">US Circuit
|
|
Nomenclature</a> helps in prototypically naming parts of a signaling system.
|
|
</li>
|
|
</ul>
|
|
|
|
<h2 id="tools">JMRI Signaling Tools</h2>
|
|
|
|
<p>It is really straight forward to use Aspect Signaling, especially if suitable signal
|
|
hardware is already configured in JMRI or you want to use Signal Masts with more than one
|
|
Signal Head. Aspect Signaling in JMRI uses of a series of Aspect definition files that come
|
|
with JMRI since version 2.9. In addition to tapping into one of the more than 20 prototypical
|
|
<a href="AspectSignaling.shtml#systems">Signaling Systems</a> that come with JMRI, you can
|
|
tweak one to suit your hardware and operations or define your own and share it as part of a
|
|
next version of JMRI.<br>
|
|
JMRI provides the following core Signaling Tools, available from the <strong>Tools >
|
|
Tables > Signals ></strong> menu:</p>
|
|
|
|
<p>1. <strong><a href="SignalHeads.shtml">Signal Head</a></strong> objects represent the
|
|
individual lights of a signal and can be created, changed, deleted and set to specific
|
|
Appearances (colors) in the <a href=
|
|
"../../../package/jmri/jmrit/beantable/SignalHeadTable.shtml">Signal Head Table</a>. One or
|
|
more Signal Heads usually are part of a Signal Mast. For signaling decoders that directly
|
|
support multiple Aspects, it may not be necessary to create individual Signal Heads before
|
|
creating Signal Mast objects.</p>
|
|
|
|
<p>2. <strong><a href="SignalMasts.shtml">Signal Mast</a></strong> objects represent an
|
|
entire signal with one or more Signal Heads. Using Signal Mast objects allows you to display
|
|
prototypical Aspects on signals. You specify what kind of <a href=
|
|
"AspectSignaling.shtml#systems">Signaling System</a> is to be used, the specific Signal Mast
|
|
type e.g. "double searchlight" or "single head dwarf" and which Signal Heads or aspect aware
|
|
signal hardware this Signal Mast is going to drive. When the <a href="#aspect">Aspect</a> of
|
|
a Signal Mast is set to e.g. "Approach medium", JMRI handles the layout communication needed
|
|
to make the signal on the layout display the right colors.<br>
|
|
<a href="../../../package/jmri/jmrit/beantable/images/SignalMasts-num.png"><img src=
|
|
"../../../package/jmri/jmrit/beantable/images/SignalMasts-num.png" width="309" height="83"
|
|
class="floatRight" alt="signal mast table"></a> Signal Masts are configured through the
|
|
<a href="../../../package/jmri/jmrit/beantable/SignalMastTable.shtml">Signal Mast Table</a>.
|
|
From the Signal Mast Table, you can create and edit Signal Masts and set individual Signal
|
|
Masts to any Aspect that they're able to display by clicking in the "Aspect" column.<br>
|
|
You can add a Signal Mast icon in the Panel Editor in the usual way. The Signal Mast icon
|
|
will display the images from the Appearance definition for that particular Signal Mast type
|
|
and Signal System.</p>
|
|
|
|
<p>3. <strong><a href="SignalGroups.shtml">Signal Groups</a></strong> are used to define a
|
|
number of Signal Heads, where only one Signal Head can be illuminated at any given time,
|
|
depending upon the Appearance (Status) of the associated Signal Mast and a set of
|
|
conditions.<br>
|
|
Signal Groups would be used where additional indicators are installed to support the main
|
|
Signal Mast, such as Junction, Route or Speed displays. These indicators provide additional
|
|
information to the driver (US: engineer) that is not given by the main Signal Mast. Such
|
|
indicators are frequently seen in European and UK signalling.</p>
|
|
|
|
<p>4. The <strong><a href="SignalMastLogic.shtml">Signal Mast Logic</a></strong> tool allows
|
|
the Signaling Logic to be built up as pairs of conditionals between Signal Masts on the
|
|
layout. Each Signal Mast Logic will use the states of Blocks, Turnouts, Sensors and other
|
|
Signal Masts to determine what Aspect a particular Signal Mast should be displaying.<br>
|
|
If the layout has been drawn up using the Layout Editor and Signal Masts have been placed on
|
|
the panel using the various tools, then it is possible for all the Signal Mast Logic to be
|
|
dynamically built, with little user intervention. For panels created with Control Panel
|
|
Editor some of this information is to be entered manually.</p>
|
|
|
|
<p>5. The <strong><a href=
|
|
"../../../package/jmri/jmrit/beantable/SignalMastRepeater.shtml">Signal Mast
|
|
Repeater</a></strong> tool allows one signal mast to follow another signal mast's aspect, or
|
|
for two signal masts to follow each other (i.e. the most-recent aspect change is reflected by
|
|
the other mast). This can be convenient for providing a duplicate of a signal's aspect via
|
|
different hardware, and may also be useful when creating "Signal Mast Logic" for complicated
|
|
track arrangements.</p>
|
|
|
|
<p>All the information in the Tables is saved with the configuration in an XML file, along
|
|
with control panel setup, Logix, Routes, and similar stuff. For more information on creating
|
|
and displaying panels, including how to show signals on your panels, please see the <a href=
|
|
"../../apps/PanelPro/index.shtml">Panels help page</a>.</p>
|
|
|
|
<p>What's next?</p>
|
|
|
|
<ul>
|
|
<li>More information on Aspect Signaling and the available options in JMRI can be found on
|
|
the <a href="AspectSignaling.shtml">Aspect Signaling help page</a>.
|
|
</li>
|
|
|
|
<li>Suzie Tall and Jim Duncan wrote <a href="SignalingSetup.shtml">Signaling Quickstart</a>
|
|
instructions.
|
|
</li>
|
|
|
|
<li>Elmer McKay provided a general overview <a href="IntroToSignalingYourMRR.shtml">How to
|
|
get started</a> with signals on your layout.
|
|
</li>
|
|
</ul>
|
|
|
|
<h2 id="advanced">Advanced Signaling</h2>
|
|
|
|
<ul>
|
|
<li>
|
|
<a href="interlock/index.shtml">Interlocking Entry/Exit</a>
|
|
</li>
|
|
|
|
<li>
|
|
<a href="#logix">Logix</a>: basic logic for controlling parts of the layout
|
|
</li>
|
|
|
|
<li>
|
|
<a href="#scripting">Scripting</a>: customize JMRI including user interaction
|
|
</li>
|
|
|
|
<li>
|
|
<a href="#automat">Automation Classes</a>
|
|
</li>
|
|
|
|
<li>
|
|
<a href="#widgets">Toolkit</a> for experienced users to do any kind of automation on a
|
|
layout by writing a new program
|
|
</li>
|
|
</ul>
|
|
|
|
<h3 id="logix">Signaling with Logix</h3>
|
|
|
|
<p>A JMRI <a href="../Logix.shtml">Logix</a> provides logic and control capabilities for JMRI
|
|
objects, including Signal Heads and Masts. Logix can be used to configure custom signaling
|
|
logic by filling out forms, without writing any code. A user defines "Conditional" logic and
|
|
the "Actions" that take place depending on the state of the logic. The following sub-sections
|
|
show how Logix can examine and control Signals.</p>
|
|
|
|
<h4 id="variable">Signal State Variables in Logix</h4>
|
|
|
|
<p>State variables related to Signal Heads and Masts currently available for use in Logix
|
|
Conditionals are listed below, along with information on each. State variables must always
|
|
evaluate to either True or False. The condition resulting in True is given for each. If the
|
|
condition is not met, the state variable evaluates to False. When a Logix is active, the
|
|
states of entities (Sensor, Turnout, Signal Mast, etc.) specified in state variables in its
|
|
Conditionals are monitored. A calculation of all Conditionals in the Logix is triggered when
|
|
any monitored state changes as noted below. <em>Note:</em> Not all Logix conditionals are
|
|
listed here.</p>
|
|
<a href="../../../package/jmri/jmrit/beantable/images/LogixSignalHeadVariable.png"><img src=
|
|
"../../../package/jmri/jmrit/beantable/images/LogixSignalHeadVariable.png" width="423"
|
|
height="92" class="floatRight" alt="signal head logix"></a>
|
|
<p>Conditionals for Variable Type "Signal Head":</p>
|
|
|
|
<ul>
|
|
<li><strong>Signal Head Appearance Equals</strong>: Evaluates to True if the Appearance of
|
|
the specified Signal Head equals the Appearance specified in the 'State' variable.
|
|
Calculation is triggered when the Appearance of the Signal Head changes.</li>
|
|
|
|
<li><strong>Signal Head Lit</strong>: Evaluates to True if the specified Signal Head is
|
|
lit.</li>
|
|
|
|
<li><strong>Signal Head Held</strong>: Evaluates to True if the specified Signal Head is
|
|
being held.</li>
|
|
</ul>
|
|
|
|
<p>Conditionals for Variable Type "Signal Mast":</p>
|
|
|
|
<ul>
|
|
<li><strong>Signal Mast Aspect Equals</strong>: Evaluates to True if the Aspect of the
|
|
specified Signal Mast equals the Aspect specified in the 'State' variable. Calculation is
|
|
triggered when the Aspect of the Signal Mast changes.</li>
|
|
|
|
<li><strong>Signal Mast Lit</strong>: Evaluates to True if the specified Signal Mast is
|
|
lit.</li>
|
|
|
|
<li><strong>Signal Mast Held</strong>: Evaluates to True if the specified Signal Mast is
|
|
being held.</li>
|
|
</ul>
|
|
|
|
<h4 id="action">Signal Actions in Logix</h4>
|
|
|
|
<p>Actions related to Signals Heads and Masts currently available for use in Logix
|
|
Conditionals are listed below along with information on each. <em>Note:</em> Not all Logix
|
|
actions are included here.</p>
|
|
|
|
<ul>
|
|
<li><strong>Set Signal Head Appearance</strong>: Sets the specified Signal Head to the
|
|
chosen Appearance. Specify the Signal Head to set by entering its System Name or User Name.
|
|
Specify the Appearance to set by choosing from the popup menu that appears after you enter
|
|
a Signal Head System Name (or drag it from one of the Pick Lists).</li>
|
|
|
|
<li><strong>Set Signal Head Held</strong>: Sets the specified Signal Head to Hold. Specify
|
|
the Signal Head to hold by entering its System Name or User Name.</li>
|
|
|
|
<li><strong>Clear Signal Head Held</strong>: Clears the Hold on the specified Signal Head.
|
|
Specify the Signal Head by entering its System Name or User Name.</li>
|
|
|
|
<li><strong>Set Signal Head Dark</strong>: Sets the specified Signal Head to Not lit.
|
|
Specify the Signal Head by entering its System Name or User Name.</li>
|
|
|
|
<li><strong>Set Signal Head Lit</strong>: Sets the specified Signal Head to Lit. Specify
|
|
the Signal Head by entering its System Name or User Name.<br></li>
|
|
|
|
<li><strong>Set Signal Mast Aspect</strong>: Sets the specified Signal Mast to the chosen
|
|
Aspect. Specify the Signal Mast to set by entering its System Name or User Name. Specify
|
|
the Aspect to set by choosing from the popup menu.</li>
|
|
|
|
<li><strong>Set Signal Mast Held</strong>: Sets the specified Signal Mast to hold. Specify
|
|
the Signal Mast to hold by entering its System Name or User Name.</li>
|
|
|
|
<li><strong>Clear Signal Mast Held</strong>: Clears the Hold on the specified Signal Mast.
|
|
Specify the Signal Mast by entering its System Name or User Name.</li>
|
|
|
|
<li><strong>Set Signal Mast Dark</strong>: Sets the specified Signal Mast to Not lit.
|
|
Specify the Signal Mast by entering its System Name or User Name.</li>
|
|
|
|
<li><strong>Clear Signal Mast Dark</strong>: Sets the specified Signal Mast to Lit. Specify
|
|
the Signal Mast by entering its System Name or User Name.<br></li>
|
|
|
|
<li><strong>Play Sound File</strong>: Plays the specified sound file (for example CTC relay
|
|
clicks).</li>
|
|
|
|
<li><strong>Run Script</strong>: Starts the specified Script.</li>
|
|
</ul>
|
|
|
|
<p>For more information see the <a href="../Logix.shtml">Logix help pages</a>.</p>
|
|
|
|
<h3 id="scripting">Scripting</h3>
|
|
<a href="../../../package/jmri/jmrit/beantable/images/jmriScriptWindow.png"><img src=
|
|
"../../../package/jmri/jmrit/beantable/images/jmriScriptWindow.png" width="250" height="136"
|
|
class="floatRight" alt="script entry window"></a>
|
|
<p>Just like other objects in JMRI you can set and read Signal Heads, Signal Masts and Signal
|
|
Mast Logic via Scripts. Instead of defining our own language to accomplish this, <a href=
|
|
"../scripting/index.shtml">JMRI Scripting</a> uses the "Python" language that's commonly used
|
|
in web development.<br>
|
|
Several methods from the jmri_default.py file can be used to work with signaling. Methods
|
|
that may be used in a Python script to interact with Signal Masts include: getAspect(),
|
|
getSignalSystem(), getValidAspects() and setAspect(Stop). See these <a href=
|
|
"AspectSignaling.shtml#mastscripting">Examples</a>.<br>
|
|
To script a Signal Head the 'getSignalHead' method can be used. Then, 'setAppearance' is a
|
|
method of the returned SignalHead object. Example:</p>
|
|
|
|
<pre>
|
|
signals.getSignalHead("IH1").setAppearance(YELLOW)
|
|
</pre>
|
|
<p><a href="../../../../../jython/SigletExample.py">SigletExample.py</a><br>
|
|
An example script for a JMRI "Siglet" in Python. It listens for changes to two Sensors and a
|
|
Turnout, and then recalculates a Signal Head Appearance based on the values.</p>
|
|
For more information see the <a href="../scripting/index.shtml">JMRI Scripting help page</a>.
|
|
<h3 id="automat">Automation Classes</h3>
|
|
JMRI provides classes to help you write Java code to control your layout. The most powerful
|
|
of these are aimed at general automation and make it easy to code your own signal logic into
|
|
the program; see the <a href="../automation/viaJava.shtml">Automation page</a>. The <a href=
|
|
"https://www.jmri.org/JavaDoc/doc/jmri/jmrit/automat/Siglet.html">"Siglet" class</a> and it's kin
|
|
are meant to make it easy to write complex custom signal logic; a variant of these was used
|
|
by Nick Kulp's for signaling automation on his <a href=
|
|
"https://www.jmri.org/community/examples/Panels-Cornwall/CornwallRunning.shtml">Cornwall
|
|
Railroad</a>.
|
|
<p>Although Automation Classes require writing code instead of just filling out a GUI form,
|
|
JMRI handles all of the details of reading status changes from the layout, writing desired
|
|
aspect changes back to the layout, and even the details of "which outputs do I have to set to
|
|
get signal Apple Siding East to show Yellow?". You can concentrate on just the signal logic
|
|
in the code you write.</p>
|
|
|
|
<h3 id="widgets">Toolkit</h3>
|
|
The entire <a href="../../doc/Technical/index.shtml">JMRI toolkit</a> is available for use if
|
|
you really want to develop new tools, controlling every detail. Programming with the JMRI
|
|
Toolkit provides control of most DCC and C/MRI systems, with useful tools for manipulating
|
|
turnouts, sensors, signals, locomotives, etc. as well as powerful tools for working on the
|
|
user screen.
|
|
<h2>Legacy tools</h2>
|
|
|
|
<ul>
|
|
<li>The JMRI <a href="../../../package/jmri/jmrit/blockboss/BlockBossFrame.shtml">Simple
|
|
Signal Logic</a> tool provided the first basic version of ABS and Interlocking signaling
|
|
using single head Signal Masts. The Simple Signal Logic (SSL) Tool is still available in
|
|
the Tools menu. However, to prevent logic conflicts and strange Signal Aspects, do not
|
|
attempt to combine the use of the SSL Tool and the newer Signal Mast Logic tools for the
|
|
same signals.
|
|
</li>
|
|
</ul>
|
|
<!--#include virtual="/help/en/parts/Footer.shtml" -->
|
|
</div>
|
|
<!-- closes #mainContent-->
|
|
</div>
|
|
<!-- closes #mBody-->
|
|
<script src="/js/help.js"></script>
|
|
</body>
|
|
</html>
|