Slots

== What are Slots? ==
Slots are a concept used in Digitrax command stations. The number of slots available determine how many locomotives you can operate. 
The concept is similar to that of a "heap" used in Computer Science: It is a portion of memory set aside by the program you are running to store variables and frequently used data. In this case, a given multifunction decoder is assigned a slot by the command station's software which contains the address, direction, speed mode, functions and consist information for use later. It also contains information regarding the throttle controlling this multifunction decoder. 
Digitrax command stations support up to 128 slots with 120 being availableSlots 0 and 121 – 127 are reserved for other purposes., except the DB150 which has only 22. The DCS100 and later command stations define the number of slots available by changing a setting.Factory default is 22 slots.This maintains backward compatibility with the earlier DB150 command station (Empire Builder/Genesis sets). 
The DCS240 command station features Expanded SlotsIntended for a club environment, the DCS240 offers 120 with the ability to add an additional 280 expanded slots (400 total). An appropriate throttle is required to use the expanded slots..
The Zephyr has ten and Zephyr Xtra features 20 slots. The Empire Builder has 22. The Chief and Super Chief have 120 slots. See the Digitrax Command Station Comparison for more info.
=== LocoNet Slot Monitor (JMRI) ===
* The Slot column indicates the slot number.
* Pressing the E-Stop button sends a stop message to that multifunction decoder 
* The Address contains the multifunction decoder's address associated with that slot
* Speed: For unconsisted addresses that are the top of a consist, this is the current speed setting. It's an internal value for consisted slots.
* Status displays the speed step modeSee Status Edit.
* Use displays one of four possiible states. See the Slot Status section below
* Release frees the slot, making it available for another multifunction decoder
* Consisted indicates the consist status, is this slot part of a consist or not, the top address, and other details.
** When consisted using UniVeral Consisting, the Consisted column indicates the top and subordinate slots
*Throttle ID indicates the throttle associated with that slot.
** The first two digits identify the type of throttle, the second its Throttle IDAn Advanced Throttle's ID number can be changed in the throttle's options. Utility throttles do not have this capability 
*# Steal changes the throttle ID to match the new throttle
*# If a slot status is Common and another throttle takes control of it the Throttle address with change. The Use state will reflect that the slot is now In Use
*# Dispatching an address will change Use from In Use to Common
* Direction indicates the current direction setting
* Functions in use are indicated by a check mark in the appropriate box.
JMRI offers a suite of LocoNet tools that can be used to monitor changes in real time.Terminology may not match that of this article
=== Slot Status ===
A slot has one of four states:
# In Use: The slot has an assigned throttle, and the command station is sending commands to the track to that multifunction decoder
# Common: Commands are being sent; No throttle assigned, contains valid data for the last multifunction decoder. 
# Idle: The command station is ignoring this slot; no commands are being sent related to this slot.
# Free: Slot is empty or has not been assigned or used. A computer running appropriate software can also clear slots.
Any slot while in use which does not receive updates from its associated throttle after a period of time may be marked as Common or Idle. If a slot's status is Common and the speed is set to Zero, the slot may be purged by the command station at a later point in time.
* If the command station does not receive LocoNet messages in a timely manner due to corrupt messages or other activities demanding time, slots may be set to Common.
==== What Does it Mean? ====
===== Common =====
A slot labelled Common is being refreshed by the command station, has no throttle (or other LocoNet device) assigned to it, and is unavailable for use with another multifunction decoder address. An excessive number of common status slots is often a result of operator discipline, or lack thereof. With proper discipline the number of slots with common status can be managed.
Releasing an address on a throttle sets the status of that slot to Common. If a LocoNet device takes control of that slot, its status will change to In Use.
If an operator inadvertently selects an incorrect address on a throttle, that address should be dispatched before a new address selection is attempted. If a new address is entered without dispatching the prior one, the first address will have its slot changed to common. By using Dispatch, the slot is made idle and available for use 
====== UniVersal Consists ======
UniVersal Consisting is the default Digitrax consisting method. Addresses in a consist remain in common status until the address(es) are removed from the consist. This ensures addresses are not removed inadvertently from a consist by reuse of their slot.
===== Idle =====
This slot is available for re-assignment to a new address. By using Dispatch the status of the slot is changed to Idle, instead of Common.
* If any functions were set, an idle slot will remain assigned to the locomotive address, despite being dispatched. These cannot be re-assigned.
** Invalid locomotive addresses will be assigned a slot which will be unavailable for future use.
* The command station will continue to assign addresses to empty slots until none are available before recycling the idle slots.
===== Purge =====
Any address which is permitted to Purge will have its slot status changed to common.
=== Slot Zero ===
Slot Zero is a feature which appeared on the DCS210This feature appears to have been removed from the DCS210+, when activated all locomotives had their speed set to zero and all functions off. It could be accessed with a DT500 throttle, or the Loco Reset button on the DCS210. The command station should be set to the Sleep Mode after use, when the system wakes all throttles will be forced to speed zero.
If there were any other active throttles connected to LocoNet when this feature is activated, they would override Slot Zero.
==== Slots = MAX Warning ====
This warning indicates the maximum number of slots available (or memory set aside for this) has been reached. Until they are cleared out, this message will persist. This can be done using an option switch (see your manual) or JMRI's LocoNet tools. Additional addresses cannot be selected when all the slots are in use, causing the Slot Max or FF message to appear on the throttle.
The main causes:
# Operators failing to zero the speed of unused addresses
# Operators failing to manually release unused locomotives from their throttles. 
===== Additional Information about the Slots = Max Warning =====
On a DT500, DT400 or DT300, the display will show Slot=Max. Older DT100 or DT200 throttles will display FF, and the Zephyr shows FULL. All these indications mean that the number of slots available is zero, as all are in use.
===== Zephyr Express =====
The DCS52 Zephyr Express' LCD will display SLOTMAX.
===== DT402 Firmware Update =====
Early firmware versions of the DT402 throttle have a bug which causes the Slot Max warning to appear before all the slots are in use. Updating the firmware should fix that issue.Current DT402 version in 2023 is 2.1. It is reported that versions 1.7 or greater are satisfactory with respect to the erroneous Slot Max warning 
=== Clearing the Slots ===
It is possible to manually clear slots using the throttle, the typical procedure with an advanced throttle is to select the locomotive address and press EXIT. This is not the same as Dispatching.
* Closing Option Switch 36 clears all slots in the command station (including “UniVersal” consists) currently in the system, leaving all other option switches as set. Once accomplished, the throttle will be able to select addresses again. 
** The exact procedure varies depending on the command station and throttle you are using; check the section for “Option Switch Setting” in your command station and throttle manuals.
** Note: Using the Release button in the JMRI slot monitor does not clear the slot. 
 Use caution when changing Option Switches: Never close Option Switch #1. KB595: Be sure that you are changing the correct Command Station Option Switches as the unit can be crippled by closing the wrong switches. NEVER CLOSE OPTION SWITCH #1!
==== General Procedure for Clearing Slots ====
The following process is recommended for clearing the slots.This process is also used with other option switches. KB595 article on Digitrax website. 
# Set the MODE toggle switch on the command station to the OP (center) position
# Use Switch Mode on the throttle
# Enter the Option Switch number to be changed
## Use Option Switch 36Refer to the manual for the correct option switch for your command station, most should use #36. to clear the slots
### Use OpSw 39 for the DCS51, as it does not have OpSw 36
# Press the "c" key on the throttle
# The command station should beep.
# Change the MODE switch position to SLEEP, then return the mode to RUN
# Turn back on using the throttle
For the DCS240 and DCS210 follow the instructions in the manual that came with your system. 
# OpSw36 is available for these two command stations. 
# To do a full factory reset, use OpSw40.
=====OpSw38 (Obsolete)=====
OpSw38 clears the Alias Address Roster, a legacy feature allowing use of extended addresses with decoders supporting only Primary addresses. The DT100 throttles can use this feature, which is rarely used today.
===Managing the Slots===
=== Expanded Slots ===
The DCS240 command station offers an additional range of slots, called Expanded Slots. These slots are only accessible to the DT402R2 or higher throttle. Legacy throttles can access 120 slots only. The DCS240 handles this automatically by identifying the throttle type. The DCS240 offers up to 400 slots in this manner, instead of the typical 120 slots offered by other command stations.The DCS240 is a separate item, not included in a starter set.
The expanded slots are useful if a lot of consists are in use. When building a consist using the expanded DT402 throttle the consist will be stored in the expanded slots. 
When controlling a consist, the top loco address controls the consist. If the consist is selected by a legacy throttle, the DCS240 will move the top loco address to the standard slot range, making a link to the other loco addresses stored in the expanded slot range. This will leave as many of the standard slots available as possible.
===Computer Interface and Software===
 If you have a computer interface for your DCC system there are software products that allow you to see a list of all the slots on your command station, and indicate the status of each slot. Some also give you the capability to free slots with the click of a mouse button.
The free JMRI software (JMRI website) contains the Slot Monitor which provides this functionality.
===Purging Made Easy===
;Don Crano, authorFrom an email written by Don Crano. Digitrax mailing list at Yahoo Groups.
====Changes in Slot Status====
If the slot status changes, or is purged by the system to be used by another decoder address, it does not mean all the data is cleared from the slot, only the status flag has changed, the data stays there to either be re-used by another LocoNet device (COMMON), or purged so new data can overwrite the existing data (IDLE). 
====Purge Timer====
Each slot has a purge timer, but that timer is not always active, this will only happen when certain criteria is met. 
How it all works:
:When a LocoNet device (Throttle) is maintaining a SLOT in the refresh stack it will be required to check that the SLOT status matches its internal state before reusing any SLOT. If a device disconnects from the LocoNet and does not access a slot within the system's PURGE time, the Master (Command Station) will force the SLOT to "COMMON" status so other system devices can use that SLOT.
:Typical purge time of a Master is from 200 to 600 seconds. Slot update activity is about every 100 seconds, i.e. if a user makes no change to a throttle/slot within 100 seconds, the throttle/device should automatically send a speed update at the current speed setting to reset the Purge timeout for that Slot. 
::Note that with a LocoNet wireless throttle, (IR/Radio) you can see the ping or update being sent while the throttle is in Power Save mode, it will wake up, send, then go back to PS approximately every 60 seconds. This prevents the system from releasing that address and making it available to another throttle. 
:Before an address will be purged, the following criteria must be meet. 
# The decoder's speed data must be at '00' or the Master (Command Station) must be set to force '00' speed upon purge. 
# Any slot with the UP-CONSIST flag set will never be purged. This indicates the slot/decoder address is part of a consist. Prevents a locomotive from being purged while in operation as part of a consist.
====Operator Discipline====
Before removing a throttle from the layout:
# Un-Link consists, that clears the UP=CONSIST flag.
# Make sure all addresses associated with the throttle are at speed '00' (stopped with the throttle closed) and/or have the Master set to reset speed to zero when the slot is purged.
# Release or Dispatch any addresses associated with the throttle.
The above steps go a long way to keeping the FF or Slot=Max status from showing up.
The term UniVersal is a Digitrax registered trade mark. It is used to name or describe their command station assisted consisting. Digitrax actually uses what is called Unified Consisting, the system allows three modes of consisting, Advanced, Basic, and UniVersal, and may be mixed,
matched, and even nested inside other consists. It is Unified because it can be done automatically without user intervention as they set up the consist.
===Option Switch Notes===
Consult the manuals for your system to determine the correct option switches for your command station.
OPSW 13 changes purge time from 600 to 200 seconds. Good for faster, more rapid purges, bad for tethered throttles, as when an operator unplugs a non-wireless throttle from the LocoNet they now have 200 seconds to plug in elsewhere. OPSW 14 can completely stop purging from happening. 
OPSW 15 controls the speed value, can be set to force speed value to 00 upon purge. This prevents runaways from happening should an address be purged while a train is in motion.
===Slot Following===
Slot Following refers to operation of a locomotive. When this happens the throttle will click every time the remote throttle initiates a speed change. The display will also change to indicate what is happening.
This feature allows two DT throttles to control a single address. Both throttles will show the speed and direction on their displays. This can be useful for training operators, allowing the mentor to take control without having to take the throttle physically from the operator.
Another application is computer control: A computer running CTC and routing control programs on LocoNet can provide some automatic control over the train. It can change speed or stop the engine, while letting the engineer holding the throttle know what is happening.
==== Operating a Stolen Address on a DT40X Throttle ====
When the command station detects that a loco address that is in-use on one of its throttles is being changed by another throttle or computer, it will cause the throttle to “click” every time it sees a remote throttle change its locomotive settings. If that locomotive is in the active throttle, its speed display will also show the changes. This is called slot following. 
This allows two DT throttles to run a single locomotive address with both throttles able to send commands to the loco. Both throttles will show the current speed and direction of the locomotive in their displays.
Slot following is useful for training new operators. The supervisor can “steal” a locomotive that is selected on a trainee’s throttle & be able to “look over the trainee’s shoulder” and closely supervise that locomotive’s control. The supervisor can gain instant override control without having to physically “grab” the trainee’s throttle. This lets you have unskilled visitors participating and enjoying operations without too much anxiety for either party.
Slot following also allows a computer on LocoNet to run CTC & routing control programs with automated control over locomotives. The computer can control speed and stop engines automatically while letting the engineer with the throttle in his hand know what is happening.
=== Ghost Throttle ===
A ghost throttle is one that you are not aware of. It was used to steal control of the locomotive and is still active. Erratic operation is often the result, as the command station overrides your throttle using the ghost throttle settings.
==Acknowledgements==
* Information on resetting command stations and other additional information is from the 'Slot=Max' document found in the Digitrax Yahoo Groups file area. Author unknown.
* Email written by the late Don Crano in 2004 on purging.
== References ==
Category:Digitrax
Category:Terms