
DCC keychain
License
:Public Domain
Description
DCC Keychain: a must for DCC train modeler. Read and Write CVs both on the programming track and on the main, using RAILCOM cutout. Interfaced with JMRI for a completely free and open source decoder management system.
Buy from JLCPCB the assembled board that embeds the following functionalities:
Download source code at https://github.com/Emppalpatine/CV, compile it and download to the microcontroller using the STC programmer connected to the 3 pads on the top of the "C" letter:
This is the particular of pin connection:
Now the CV programmer is ready to operate, connecting the USB cable (toward PC) and the DCC output connection (toward rails, loco emulator in photo with ESU LokPilot 5).
Now download and install the last version of JMRI on the PC (https://www.jmri.org/). Start "DecoderPro" and set the connection to the layout as for the following picture (setting the COM port to the correct value for your system - in my PC is COM8):
and select on the page "defaults" the following options:
once configured the link and the options, return on the main page of DecoderPro and then select:
-
Programming track (page top right): "LocoNet" and mode "Direct Byte"
-
Select the decoder you want program from the roster list
-
Select "Programming Track" or "Main Track" options
-
Push the button "Program" that will open the decoder program windows
CV read and write
The CVs are read and written in the following page of DecoderPro (for both programming track and main track). Each CV is read simply pressing the button "Read" and the value in yellow (if the read-out is correct) will become white. If there are some errors in readout, the cell value will become red. To Write a CV, write the new value in the cell "Value" and press "Write": in case of errors the cell will become red, otherwise green.
Read-out speed
The CVs are read (on the programming track) with the DIRECT BIT mode. Each bit is check for "one " value and at the end thecomplete CV is checked with DIRECT BYTE to give a error-less operations. The readout speed is approximately one CV every second:
Readout on the programming track
The following link shows the speed for the readout of the LokPilot 5 speed table on the programming track:
Read LokPilot 5 speed table on the programming track
for comparison the same read-out of the LokPilot 5 speed table is done using the programming on the main (POM) mode:
Readout of the LokPilot 5 speed table in POM mode
Programmer operative parameters change
The programmer has been designed to work with the largest number of decoders on the market, but there may be some that, for correct management, require a customization of the programmer. In this CV programmer have been inserted 8 parameters that can be modified by the user such as LocoNet LNCV.
How modify a LNCV in DecoderPro:
-
From the main page, open the "Loconet" menu, then select "Configure LNCV modules" and this page will be displayed:

Set the "article number" to "1111" and the "module address" to "1", then push "Start Module Programming". The LED on the programmer will start to fast blink. The you can read and modify the parameters in the LNCV from 1 to 8.


Design Drawing

BOM


Project Members

Comment