I'm trying to set up my first DCC++ base station with JMRI, and I'm having a problem. I'm using an Arduino Clone, and a Deek-Robot motor shield. I can get the track power LED's to turn on, but I can't get power to the track. I'm using a 12v power supply, and used a multi-meter to verify that I have 12v to the power inputs. When the track power is on I have .22 volts on both the programming track and the main. I have 5 connected to 13 and 10 connected to 12. I have used the Uno for other sketches and it works fine. I have tried it with both DCC++ Controller and JMRI. I bought two motor shields and they both have the same result. Thoughts????? I get the following errors when compiling /Users/r/Documents/Arduino/libraries/DCCpp_Uno/DCCpp_Uno.ino:427:152: warning: backslash and newline separated by space [enabled by default] R.currentBit=0; /* reset current bit pointer and determine which Register and Packet to process next--- */ \ ^ /Users/r/Documents/Arduino/libraries/DCCpp_Uno/DCCpp_Uno.ino:433:100: warning: backslash and newline separated by space [enabled by default] R.tempPacket=R.currentReg->activePacket; /* flip active and update Packets */ \ ^ /Users/r/Documents/Arduino/libraries/DCCpp_Uno/DCCpp_Uno.ino:449:103: warning: backslash and newline separated by space [enabled by default] } /* END-ELSE */ \ ^ /Users/r/Documents/Arduino/libraries/DCCpp_Uno/DCCpp_Uno.ino:450:88: warning: backslash and newline separated by space [enabled by default] \ ^ /Users/r/Documents/Arduino/libraries/DCCpp_Uno/DCCpp_Uno.ino:196:59: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings] CurrentMonitor mainMonitor(CURRENT_MONITOR_PIN_MAIN,"<p2>"); // create monitor for current on Main Track ^ /Users/r/Documents/Arduino/libraries/DCCpp_Uno/DCCpp_Uno.ino:197:59: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings] CurrentMonitor progMonitor(CURRENT_MONITOR_PIN_PROG,"<p3>"); // create monitor for current on Program Track UNO: https://www.amazon.com/gp/product/B00P2FX9WY/ref=oh_aui_detailpage_o05_s00?ie=UTF8&psc=1 Motor Shield: http://www.ebay.com/itm/310787745501?_trksid=p2060353.m2749.l2649&ssPageName=STRK:MEBIDX:IT
for the motor shield, did you connect the 12vdc to the inputs on it and cut the VIN and BRAKE traces on the back?
cut the traces for the BRAKE and it should work... refer to https://github.com/DccPlusPlus/Documentation/blob/master/Motor Shield Pin Mappings.pdf page 3. Also test the voltage across the track pins, it should be around 11-11.5V AC since you have a 12V DC supply.
I never thought to test it with AC. JMRI was able to read the decoder, but I wasn't able to get it to run. I measured the track voltage and it was 10.8 AC, is that too low to run a HO train? I'll try it tomorrow with an 18 volt pack. I wanted to start with lower voltage in case I messed up.
Hello, If you are using HO Scale locomotives you will need a higher power supply. I use a Pololu motor shield, which is rated for higher voltages, and a commercial power supply that I got with my digitrax DCC system which is also rated for use with N, HO, G scale and has a voltage selector on it with an onboard voltage meter so I know how much voltage is being supplied at any given time.
Bumping on this... First time setting up DCC and decided to use DCC++. (For the low cost alternative). So an Elegoo Mega board with the Pololu motor shield. Serial comms from the computer to the "BaseStation" seem good. Just no communication to the decoder. I too thought it might be a voltage issue. but Im hesitant in going with a higher voltage since in big bold letters in the Digitrax manual it says no higher than 16volts. Well, its DCC, You cant measure track voltage in DC with a simple multimeter. and alas I dont have an oscilliscope. TX/RX lights flicker with commands. voltage from the Mega does not power up the Pololu. so no cross voltage issues. power to Pololu makes a nice blue light with power supplied. Arduino IDE serial monitor <1> does turn on the red/green lights on both outputs, and <0> turns them off. JMRI power button does the same thing. AC Voltage at the track was measured to be 24Vs (?) when powered on, 0 when off. 3 different decoders. DigiTrax - 2 of the 126 decoders and 1 166 decoder. JMRI will not read CVs. Says "308 - No acknowledge from locomotive" when trying to identify. Any suggestions? Thank you. Steve
A DCC system outputs a constant voltage of about 14.5V AC. Be sure to use AC voltage measurement mode of your multimeter and ~not~ DC mode.
The voltage is not constant on a DCC rail, this is an irregular square shaped signal of 14.5v x 2 in HO, 12v x 2 in N (https://www.nmra.org/sites/default/files/standards/sandrp/pdf/s-9.1_electrical_standards_2006.pdf)...
Bumping on this again...sorry I'm new and only got my DCC++ gadget four days ago. Cutting the BRAKE track on the motor shield isn't mentioned in the how-to videos from youtube. Is this something that has come to light since then? I have a followup question as well--what happens if you DON'T cut the brake track? Recommended doesn't equal mandatory, so if I don't care about the extra pins (which I don't), will DCC++ still work correctly? I have genuine UNO and motor shield, no clones here!
The youtube videos are very old and are not guaranteed to match up with the current code available on GitHub. By not cutting the brake pin trace, if the pin transitions to a HIGH state for any reason the h-bridge will cut all track output. The recommendation to cut the trace is not really tied to only freeing up the pin. It ensures that the track output is not unintentionally cut off by an unintended change in the pin state.
I'm glad I asked! Thanks for the heads-up, I'll do it today. But on reflection, I think I asked the wrong question. Where are the most up-to-date instructions for setting up the Arduino and motor shield? There may be other things I need to know about because I only looked at the old YT vids. Thank you, Charles
It is split between a few places... But the GitHub repositories will be your best source of info on the original Arduino AVR based DCC++ program: https://github.com/DccPlusPlus/BaseStation and https://github.com/DccPlusPlus/Documentation
OK, so that covers cutting the BRAKE traces. I've already cut Vin Connect on the Uno in line with the old instructions. Since it hasn't exploded and seems to be working OK, I gather this now doesn't have to be done on the shield as well? Otherwise looks like I'm good to go when my decoders turn up!
If I might make a suggestion--if this board supports pinning threads, might it not be worthwhile to gather the most up to date instructions and pin them as a resource for noobs such as myself? If there are forks going on, this is news to me and I don't know where they are or why. There are now over 3000 messages to sift through to find this information. Since Gregg isn't active at the moment--which was also news to me, but I noticed it in a random message I looked at yesterday, so it might be the case--I don't want to break something or run across avoidable problems, by using out of date instructions. Thanks! Charles
VIN should also be cut. This prevents feeding the DCC supply to the Arduino side, if you are using over 12VDC it can cause the voltage regulator on the Arduino to fail (check the docs for the specific Arduino board for it's limits). It is generally safer to cut the trace and supply independent voltages. Gregg has not been active for quite some time unfortunately. His version of the DCC++ project is virtually dead due to this. Forks can be found from GitHub as well as on here. As for why that is generally due to lack of activity on the original code base.
I'm going to post a new topic summarising what I've done so far rather than keep adding to this thread.