Version 5.0 IS HERE!

Click The Link For DCC-EX Website

New Motor Shield Available NOW & Version 5.0 Is Finally Here

DCC-EX Website will have further documentation for the EX-MotorShield8874, and extended support in software will be included in the EX-CommandStation v5.0 release. Can’t wait to get started on it after I finish with my Kit Build Giveaways.

My EX Motor Shield 8874

Has Arrived & Version 5.0 Is Here

Soldered all the connections on the shield and tested it out with the <1> and <0> to turn power on and back off, everything worked well. I then hooked it up to my layout in the train room and ran a few trains. Much better with only one power source and the ability to just unplug track power when needed to remove from layout  to program on the computer.

Tested the new motor shield on my layout and it works great. I will be doing more tests with it once I install Version 5.0 after I’m finished with my Projects of building a few more structure kits and laying track in my industrial area. I’ve been putting that off for too long.

You can watch my video of me soldering the connections HERE.

You can access all the information on the Motor Shield HERE

Video Announcement Of Shield

Everything About DCC-EX In My Train Room & My Experiences

This page is my adventure with DCC-EX.  I will show you everything you need to know so you can get started in your train room to build a Command Station for DCC-EX!

I have two separate projects going on right now;

Train Room ……………… I will walk you through the steps to build your own Command Station

Test Track ……………….. Under Construction   More To Come

What To Expect On This Page & More

Train Room

History Of DCC++
How I Got Involved
My Plans
Basic Components Needed
Where To Purchase
Choosing Components
Assembly
Installing & Tweaking Software
Upload Power Up & Test The Operation

Test Track

Under Construction

What I want To Test
Area Prep
Components Needed
Where To Purchase
Assembly
Experimentation
Testing & Re-Testing
Results

For those that are interested in this concept,

but feel electronics and coding is too much to handle,

click the EASY Button!

Brief History Of DCC++

On August 25 2015 Gregg E. Berman introduced DCC++ to the world through Trainboard Forum his creation. It is an automated modal railroad in N Scale he built for himself using his knowledge of coding with C++ and java. See what he said in his first post:
Gregg’s first post on Trainboard DCC++
Little did he know what impact he would have on the model railroading community!

How I Got Involved

My first exposure to DCC++EX was many years ago on the Trainboard Forum where interested model railroaders were attempting to expand on the original DCC++ created by Gregg Berman who participated in the forum and then started the DCC++ thread. Gregg helped out many who were interested including a few that developed DCC++EX, then without notice, Gregg disappeared from the forum. This was before the EX was added, and the developers working on this decided to completely rewrite the code to fit what the interests were of fellow model railroaders.
Many years later The Dev Team gave it a new look,  built a web site DCC-EX and also a GitHub Server.
Around the beginning of August of 2020, I saw a post on the  FaceBook Group DCC++ and Arduino Model Railroading which got me to dive into this with enthusiasm. I liked what I saw and started building my own Command Station (CS).  I had some help from  Fred Decker to set everything up so I could post two videos on what they were working on at the time.  “Easiest Way Yet To Install DCC++ Without A Sketch Or Arduino IDE” and about 10 days later,  “DCC++EX Wifi & Web Throttle” These two videos had some model railroaders interested even more because of the ease of installation and the additional features.
I was excited about this because I had built several modules in my living room along the walls and everything was going to be handled with Arduino, including the CS with DCC++. These new features available in DCC++EX was a game changer for my plans.
Prior to this, I was working on JMRI & C/MRI and even versions of Geoff Bunza’s ideas with JMRI. I was looking for a way to control everything on this new project, such as signaling, turnouts, and LED control. The further I got into this project, the more issues I found that this old technology was to hard to adapt to what I wanted to have on my layout. These new features in DCC-EX was exactly what I was looking for.
But I ran into one roadblock—>

Present Day

 

The Dev Team finally drops the ++ from the name!

No more DCC++EX. Now everything will be referred to as DCC-EX to conform to all the other branding.
Shortly after those videos, we started talking about moving into a single story home so we wouldn’t have to navigate the stairs daily. So everything in the train room came to a screeching halt, everything was disassembled and placed in storage till we moved and got set up in our new home. Now, here we are two years later, much wiser, new train room, new layout, and ready for the next project.
That new project is getting back to DCC-EX.. I announced this on a recent live stream (July 25 Live Stream) and surprisingly Kevin C Smith for the DCC++EX Dev Team was in the chat giving updates on what was available now and what to look forward to in the next version update. This got me more excited to move on even faster with this project. In the next few days, I caught up on all the posts on Discord, and read through all the documentation on the DCC-EX web site. I was ready to upload the new version onto 2 of my Command Stations. One to run the trains in the train room and another to do testing in the Family Room on my new setup (Pictures below). I want to test as many of the new features as I can in a controlled environment on a loop with one or two sidings.
DCC-EX has expanded even more with Version 4.0 which includes;
EXRAIL EXtended Railroad Automation Instruction Language to automate Sensors, Servos/Turnouts, Signals and Accessories.
HAL Hardware Abstract Layer to automatically predefined and connect accessory boards like PCA9685 Servo/Signal boards and MCP 230137 GPIO extender boards.
multicast Dynamic Network Server (mDNS) enhancement provides Engine Driver & WiThrottle Discovered Server connections to a DCC++EX Command Station.
In addition the DCC-EX Dev Team has been working on new future projects such as “Track ManagerTM” which will allow both DCC {pwm} & DC {pwm} pulse width modulation generated waveforms to operate simultaneously on separate insulated tracks/blocks on the same CS.
While assembling my 2 Command Stations, I discovered a few shortcuts and items to look out for if you are attempting to build your own CS. This is what I will document on this page!
If you’re not hooked yet, I hope what I show here gets you interested in DCC-EX. For those of you who are already interested in this project, I hope it helps you along the way if you are encountering any stumbling blocks in your attempt to get started. Remember, you can always go on DCC-EX Discord to receive help right from the Dev Team!

Train Room Operation

In the train room I will be replacing My Digitrax BD150 Base Station with my DCC-EX Command Station Version 4.0. It was very simple to make the switch. I just had to unplug the connector from the base station and connect the new CS to the Bus wires under the module. I do not have any districts on this layout yet, this made it very easy to install. My new CS will be located at the end of the first level module that has the Industrial Yard. Right behind where I sit for my live streams.
Components used for this CS is an:
Elegoo Mega 2560
Deek-Robot Motor Shield
Makerfabs Wifi Shield
15 VDC 3 A Switching Power Supply
9 VDC 1 A Wall Wart
2 Jumpers M-F
Barrell Connector

Where To Buy

All components can be easily obtained through my Amazon Storefront with the exception of the Makerfabs wifi shield. This shield can be obtained directly from Makerfabs website. Other options are AliExpress or Banggood.

Choosing Components

Choosing the right components based on your budget, experience, and requirements is your first step in building a Command Station (CS). If you were already experimenting with DCC++ in the past, you are familiar with nearly all the components for your CS and may need to just upgrade a few because of the additional features. I’m going to assume you’re starting from scratch here!
Everything you need to know about DCC-EX but were afraid to ask is available in an easy to follow format on the DCC-EX website, which breaks the experience level into three categories.
Conductor         Just wants to operate trains!
Tinkerer            Likes building things themselves!
Engineer          Digs deeper into how things work!
I will put myself loosely into the last category, Engineer. I say loosely because I like to dig into things even though at times, I  may not know what I’m doing. But here, I will show you the steps I took, what I found, what to avoid, and some tips to make things go a little simpler for you.
The below graphics indicates the average price of the components when purchased through Amazon. There are other sources to purchase these items, you may have your favorite. The only exception is the Makerfabs Wifi shield, which I could only find directly from the manufacturer. You may be able to source this out at your favorite supplier. There are other substitutes available, I listed what I am using. Check the DCC-Ex website for all the tested brands.

Less Expensive Components

High End Components

Train Room CS

For this build, I used components I already had from previous projects.
The Arduino board is an Elegoo Mega 2560. I have been using the Elegoo brand for many years and have had excellent results with their product and customer service. The Dev Team recommends a Mega over the original Uno because of the advanced features, additional pins, and more EEPROM memory.
The motor shield is a Deek Robot. I tested these for use with DCC++ long before they were recommended for use here. Because of their popularity and price, they are out of stock more often than not. You can purchase an original Arduino motor shield at a higher cost, or there are other brands available from other vendors which are similar to the ones listed. I like to stay with the brands and vendors I’m familiar with! Check the recommendations HERE if you seek different motor shields.
The wifi shield is from Makerfabs. I used this two years ago to demonstrate the Web Throttle when DCC++EX first tested stand alone wifi for their CS. I always purchase two each of everything when testing something new. Just in case something goes wrong. I would be set up for my test track except the second shield was defective. It’s been banged around in storage for over two years now.
The power supply for the motor shield is a 15VDC 3A Brick style. The voltage you need may vary depending on the scale your model railroad is! Check on the DCC-Ex website for their recommended voltages.
If your CS is not connected to a computer, such as while using JMRI for operations, you will need a power supply to power the Mega. I have a 9VDC 1A PS for this. Even though Arduino states the barrel jack can handle more voltage, anything over 9 volts is dissipated as heat and may damage the onboard voltage regulator! If you are using a PS for the Arduino and choose to hook up to a computer later to upload code or do tests through a serial monitor, you can safely have the PS and the USB cable connected at the same time. The Arduino will only use one power source at a time!
Once you have all the components in front of you. On the Motor shield, you will need to either cut the Vin trace underneath the board, or cut or bend the Vin Pin so it doesn’t connect to the Arduino when you stack the devices together! This is the most important step here!

Connecting The Devices Together

Before we get started with installing the software on the Arduino board, I want to give you some pointers on the connections on the devices and between them.
Power to the motor shield comes in on the two outer connections on the screw terminals. You will need a female barrel connector from the motor shield  to match up with the barrel connector on the PS. To do this, tighten a wire to each terminal on the board to the back of the barrel connector, making sure to observe the polarity marked on each!
I have had no issues with the barrel connectors when attaching them together as a set as sold. But when I attached it to the PS, I was not getting good contact between the PS and the internal pin on the connector from the shield. This had me baffled because I thought I had a bad motor shield when I was testing later on. I ended up using a connector designed for a PCB. This work perfectly. I had to solder the wires from the connector on the shield to the pins on the connector. Be careful to observe which pins are the ones you need. There is three pins altogether, one is offset from center, this one is not used!
NMRA &  DCC Wici recommend a heavy wire for the bus to your layout, typically a 14 gauge wire is used. Unfortunately, this will not fit in the shield terminals for the track power. You can use a smaller wire for a short distance same as you would for feeders in this case. I used a 12 inch length of 20 gauge speaker wire pair on my connection. Just long enough to connect to the bus wire under the module.
There was an issue with the screw terminals once I removed the old wires from the shield. I ended up soldering the speaker wires to the posts on the bottom of the board. This worked out much better since it seems like a more secure fit.
For the wifi shield, two jumper wires are needed for the connection between the Mega and the wifi shield. On the Mega, Pin 18 is TX, Pin 19 is RX. Connect the TX on the Mega to the RX on the wifi shield. Connect the RX on the Mega to the TX on the wifi shield. I connected mine to the ones identified as 7! You can use any pair.  This shield comes with two jumpers across the TX to Digital & RX to Digital. Please remove these before you begin!   
Now that you have everything connected together and the wires attached, it’s time to connect to the computer to upload the sketch!
Pin Designation
Barrel Connector
Motor Board Connections
WiFi Jumpers

Installing The Software

There are two methods of installing the software on the Arduino. The easy way falls under the Conductor Category. If you do not feel comfortable with making changes within the sketch, you should use this method. You can refer to the DCC-EX website for these instructions. This method can easily be used on a Mac, PC or Linux device such as Raspberry Pi!
I will walk you through how I did mine on a PC! If you do not already have the Arduinoo IDE, you can download load it HERE. Instructions are included on how to do this. You can also refer to my series “Arduino Made Easy(er)” for a tutorial on getting started with Arduino.
I am currently using CommandStation-EX v4.0.0 Production Release, this can be downloaded <HERE>   Download the zip file from this page by clicking on the name of the file, CommandStation-EX.zip. You can read all about all the features and the known issues on this page.
Unzip this file and place it in the root directory of your Arduino folder. make sure you move the entire folder together. Refer to the graphic on the right. Once the folder is in the proper place, expand the contents, right click on config.example.h. Choose Rename, and rename it config.h. This will give you the file you will need to add information to once you have the project open.
Run the Arduino IDE. If this is your first time, a blank sketch will open. If you are familiar with Arduino and worked with sketches before, your last sketch will open. From the top menu click File/Open, find the location of the folder CommandStation-EX, the click on the file with the same name (it will have an Arduino symbol next t it). This will open up your CommandStation-EX project sketch and related files which show up as additional tabs. Watch the video for an in-depth look of the steps to take to edit the config.h file.
There are other files that can be edited, but we will cover those at a later time with the Test Track Project. This is a little more advanced than just setting up the CS to get trains running. Now it’s time to upload this project onto your Arduino and have some fun!
Root & config.h graphic
Click For Video

Upload – Power Up – Test

This is what we’ve all been waiting for! If you plan on a wireless throttle, I hope you watched the video in the last step on how to edit the config.h file.
Connect your USB cable between your computer and your CS. Do Not power up the power supplies at this time.  Make sure your device is set up correctly and you choose the correct Port #. If you are not familiar with these steps watch <THIS VIDEO>    Click the Compile Icon at the top left, just under the Menu Bar. This may take a few minutes. When finished, power up your power supplies and connect your main track to the two terminals marked A+ & A-. The B+ & B- are for the Program Track, you can wire them to a program track later or just leave them empty for now. We want to test to see if this works.
At the top right of the Arduino IDE window is a magnifying glass, clicking on this will open the serial monitor. Once open, the page will populate with information about your CS. If you installed a wifi board on your stack you will see info there about your network name and password several lines down. Make sure these are correct before attempting to use a wireless throttle.
On the Input Line just under where you see the COMxx, enter without the quotation marks “<1>” and press Enter. This will turn power onto your Motor Shield, you should see all four LEDs light up. This indicates everything is working properly.
You can now enter in that same line “<0>” and press Enter. This will turn the power off to the tracks. Success! If you plan on using JMRI to operate your trains, leave the USB cable attached and open JMRI on your computer. This step is covered under another topic   <HERE>
I am running my trains directly from an old Android cell phone with Engine Driver. If you have an Apple device you can use WiThrottle. You can get either one from the appropriate app store. There are other apps and methods of controlling your trains. You can refer to the Choosing A Controller On the  DCC++EX web page for more information.
Input Line
Serial Monitor

Throttle Connection

Now your ready to connect your wireless throttle! Whatever app you are using, it should detect the network automatically under “Discovered Servers”. If not, you will have to enter the Server address & Port, which is typically 192.168.1.xx and 2560 for the Port. You can check the readout on the serial monitor for your address if you do not know it. It will be listed on one of the lines that states “wifi check.” Also, make sure your powers supplies are properly connected to your Arduino & motor shield. This is what powers the wifi board.
Select your server, this should take you to the two throttles available. At the top right are three vertical dots, tap them, this will take you to a drop down menu where you will see Power, tap that.
The Control Layout Power Screen will appear. Tap the Power Icon, then click Close. You’ll be taken back to the Throttles.
You should see the two LEDs adjacent to A+ & A- light up.
Now you can select the loco(s) you would like to run by pressing Select above either throttle. The first radio button will be selected, you can enter the address on the Address line below, then press Acquire. You will be taken back to the throttle.
Now it’s time to enjoy running your trains!
Connect To Server
Acquire Address
Throttles

VIDEO: How I Built A DCC++EX CS For My Train Room

YouTube player
If the Command Station is more than what you want to tackle at the moment but still want to try Arduino, check out the Arduino products I enjoy using and highly recommend. I have purchased each one of these myself, some multiple times. The Elegoo Super Starter Kit is a great tool for learning Arduino! Getting Started With Sketches is a great place to learn a little more about what you can accomplish!

Still Under Construction

More To Come Below

/ / / / / / / / / / / / / / / / / / / / / / / / / / / / / / / / / / / / /

Click To Watch Video

Building The Testing Ground

Here is a short video of me building the layout in the family room where I will set up the test track to do all my testing.
I purchased a 40″ X 96″ platform several months ago from the Re Store in Lakeland for a great price considering the current price of plywood. My original plan was to use it in the train room, but you know how plans change as we have new ideas that come to mind. We are so easily swayed! LOL
As you can see, I still have many pieces of the old layout stored in this room which I am slowly using on the new layout in the train room.
Waiting on some supplies right now so I can get started laying track and start playing!