KB519: Decoder Lock CV15 & CV16
This article was last updated on Sept. 3, 2011, 11:17 a.m. | Print Article | Leave Feedback
Decoder Lock lets you use more than one decoder in a locomotive and be able to program their CVs separately. This is a manufacturer specific CV. The instructions provided here work for Digitrax decoders. If you are using decoders from another manufacturer, please consult your decoder instructions for how this feature works with the decoder you have installed.
For example, if you use a mobile decoder and a sound decoder together in your locomotive, you can use the same mobile decoder address during operation and when programming you can unlock only the one you want to program.
Since all decoders with the same address will accept programming commands directed to that address, decoder lock avoids the inconvenience of uninstalling one or more of the decoders in order to program CVs in just one of the decoders installed in the loco.
CV16 is used to set the ID number of each decoder installed in the locomotive.
CV16 can be programmed to a value from 0 to 7 inclusive. This value identifies a single decoder. A unique value must be assigned to each decoder installed in a particular locomotive so that it can be selectively unlocked for programming later.
Digitrax recommends using the following values for CV16 for consistency:
0: Factory Default Value-Decoder is not locked
1: Motor decoder
2: Sound decoder
3: Function-only decoder (e.g. for additional lights)
4-7: Additional Decoders installed in the locomotive.
CV15 is used to select the target decoder that will accept programming commands.
When the values in CV15 and CV16 are equal, all CVs in the target decoder can be programmed.
When the values in CV15 and CV16 are not equal, only CV15 can be programmed.
Digitrax uses CV54 bit 6=1 to disable the decoder lock feature.
The Factory Default Reset CV (CV08=08) will not work on decoders that are locked unless the CV15 and CV16 values are equal. This prevents the user from accidentally resetting multiple decoders at the same time, and losing the ability to separately address them for programming purposes.
Note: If you are installing only one decoder in a locomotive, there is no need to modify the default values of zero in CV15 and CV16.
To configure unlocked decoders at installation: Each decoder is shipped from the factory unlocked with both CV15 & CV16 programmed to a value of 0.
Before installing each unlocked decoder in the locomotive:
a) Connect the target decoder to the programming track all by itself
b) Write a value of 08 to CV08 to ensure CV15 and CV16 are both zero
c) Optional: Read CV15 to confirm that the CV Value is 0 meaning that the decoder is unlocked.
d) Program CV values desired into any CVs in the target decoder. Program the address to the one you will use for all of the decoders that will be locked together.
e) When you are finished programming the CVs, lock the decoder by writing CV16 to the desired ID number, for example 02 for a sound decoder. This step locks the target decoder to ID 02.
f) Disconnect the target decoder from the programming track and install it in the locomotive
g) Repeat in turn for each decoder to be installed in the locomotive. Note that this decoder lock method can be performed even when only a write-only programming method is available. Also, it is possible to use a "legacy" non-lock version decoder along with new lock capable decoder(s). In this case, program the decoders with the lock feature first, locking each one when programming is complete, and leave the non-lockable decoder to be programmed last.
To access a decoder after installation:
a) When you want to program CVs in the target decoder with ID XX again, unlock it by programming CV15 to match the ID XX programmed in CV16. In the case of the example decoder, program CV15 to 02.
b) Once the decoder is unlocked, program CVs as desired.
c) When programming is finished, lock the decoder by programming CV15 to 0.
To identify the decoder(s) present in a locomotive:
a) Write a 0 to CV15
b) Attempt to read a 0 from CV16.
c) If no acknowledge is received, there is no decoder with ID 0. If an acknowledge is received, a decoder with ID 0 exists.
Repeat this process for ID 1 through 7 to check for those IDs.
Because the ID values are low, a successful read is quite fast. An unsuccessful read, i.e. when the decoder is not present, will take some time on many existing command stations, but eventually give an answer.