DCC++ Diagnostics <D> not working <Z> returns no outputs <X>

David Mease Mar 31, 2017

  1. David Mease

    David Mease New Member

    3
    3
    1
    I'm setting up my first DCC++ unit and am having no luck.
    Setup:
    True Arduino Uno R3
    Deek-Robot motor shield connected with 9 volts, trace cut
    latest Arduino software on Macbook Pro
    latest DCC++ sketch

    jumpers on shield 5-13, 10-12

    When I open the serial monitor I get the following message:
    <iDCC++ BASE STATION FOR ARDUINO UNO / ARDUINO MOTOR SHIELD: BUILD Mar 30 2017 15:24:48><N0: SERIAL>

    What does the <N0: SERIAL> indicate?

    Send <1> command all lights on on shield outputs light, <p1> returned in monitor. Send <0> lights go out and p0 returned.

    Send <Z> command returns <X> meaning no outputs defined. Should this show the mappings of the jumpers obtained from the DCCpp_Uno.h file?

    Send <D> diagnostics command and nothing happens. Diagnostics page says the shield lights should all flash. No message returned to monitor. D page says I should see "Entering diagnostic mode...".

    When I use JMRI Decoder Pro shows no available connection on programming or operating tracks.

    Any help to move forward is appreciated.
     
    Scott Eric Catalano likes this.
  2. Armorican

    Armorican New Member

    6
    7
    5
    Hi David,
    <Edit : I read too fast, everything I mentioned can be discarded>
     
    Scott Eric Catalano likes this.
  3. Jimbo20

    Jimbo20 TrainBoard Member

    274
    178
    11
    Hi David,
    I am not that experienced (yet!) with DCC++, but hopefully I can help you with a few of your questions;

    >>What does the <N0: SERIAL> indicate?

    The interface selected is type 0 (meaning serial)
    If you were configured using Ethernet, it would say <N1: Ethernet.Ip address>

    Your <1> and <0> commands seem to be turning the power to the tracks on and off correctly, with the correct response of <p1> and <P0>

    >>Send <Z> command returns <X> meaning no outputs defined. Should this show the mappings of the jumpers obtained from the DCCpp_Uno.h file?

    My understanding is that the <Z> command shows the definitions of any configured custom input or output pins for use perhaps for controlling lights or monitoring sensors etc. These definitions are stored in EEPROM and not as far as I know in the DCCpp_Uno.h file.

    Entering <D> on my arduino certainly causes lights to flash and "Entering diagnostic mode..." to be returned. I believe that the some versions of DCC++ S/W didn't include the diagnostic mode. I got mine from here:

    https://github.com/DccPlusPlus/BaseStation


    Also if you haven't already seen this, this page gives a lot of info about the commands:
    https://github.com/DccPlusPlus/BaseStation/wiki/Commands-for-DCCpp-BaseStation

    I hope this helps you,

    Jim
     
    Scott Eric Catalano likes this.
  4. David Mease

    David Mease New Member

    3
    3
    1
    Thanks for the info. I downloaded from the same location and reviewed that document many times.

    Today I ordered a Arduino motor shield. I'll see if that makes a difference over the Deek board.

    I also tried this with an Mega 2560 with the same results so maybe there is an issue with the sketch. If I remember correctly there was a developer version you can download. Maybe that has the diagnostics.

    David


     
    Scott Eric Catalano likes this.
  5. Jimbo20

    Jimbo20 TrainBoard Member

    274
    178
    11
    Note that to run the diganostic you must enter upper case D (<D>)

    I had a look at the code and the <D> diagnostic routine is in SerialCommand.cpp towards the bottom.
    You should be able to see the code if you click on the SerialCommand.cpp tab at the top of the code window in your Arduino IDE. If the case 'D' routine isn't there , then you must have the wrong version. If it is there then I don'y know why it won't start on yours. I can even run the commands with a bare arduino (no shields plugged in)

    Code:
        case 'D':       // <D> 
    /*
     *    changes the clock speed of the chip and the pre-scaler for the timers so that you can visually see the DCC signals flickering with an LED
     *    SERIAL COMMUNICAITON WILL BE INTERUPTED ONCE THIS COMMAND IS ISSUED - MUST RESET BOARD OR RE-OPEN SERIAL WINDOW TO RE-ESTABLISH COMMS
     */
        Serial.println("\nEntering Diagnostic Mode...");  ....etc
    Have you seen the following page? - it may help

    https://github.com/DccPlusPlus/BaseStation/wiki/Diagnostics---D---Command

    Jim
     
    Scott Eric Catalano likes this.
  6. David Mease

    David Mease New Member

    3
    3
    1

    Just before you posted this I actually searched the code myself for the command discovering the SerialCommand.cpp file and found I wasn't using the latest version. Once I downloaded the code from 1/2016 it worked fine.

    I also got it working in Decoder Pro. Though DP still doesn't show either Operations or Programming are available as both are red at the bottom of the roster window. I found if I manually turn it on everything works. Not sure how you are supposed to select between ops or prog tracks though.

    David
     
    Scott Eric Catalano likes this.

Share This Page