Compiling DCC++ on a Pi (HELP)

rdkdrn Feb 10, 2018

  1. rdkdrn

    rdkdrn New Member

    6
    1
    1
    Hey guys, getting back into the hobby after many years being out. I am trying to compile the original DCC++ code using the Raspberry PI Arduino IDE and I'm getting a compile error.

    "Sensor.cpp:61:20: fatal error: EEPROM.h: No such file or directory"

    Any help would be appreciated. I have an UNO clone and no motor shield yet. Any help would be appreciated.
     
  2. drken

    drken TrainBoard Member

    344
    200
    19
    That error means you're missing the EEPROM library, an add-on to the Arduino programming language (DCC++ uses a few of its own) that allows you to save various settings to what is essentially a very tiny flashdrive, which is odd because that's one of the libraries included with the IDE. Check to see if it's installed. From the Sketch menu select "Include Library" this should give you a list of all the installed libraries. Check to see if it's there. If it's not, you might want to try reinstalling the IDE. Have you successfully run other sketches? If the IDE isn't working you might want to try installing Ubuntu Mate instead of the Rasbian available from raspberrypi.org. I've had issues trying to run Arduinos from Rasbian. Good luck.

    Of course, I've don't remember ever trying to run DCC++ without a motor shield attached, so it may be just that.
     
  3. crusader27529

    crusader27529 TrainBoard Member

    247
    167
    11
    The critical nature of the timing for the DCC signal depends on specific settings for the ARDUINO hardware, and even if you get it to compile, it's NOT likely to work.

    As to the missing library, even if it was available, the same issue remains.....the Arduino library won't work on a Raspberry PI. I'm not knowledgable about any RPI hardware and EEPROM, or even if it has any available to an application.

    The code is designed for the Arduino hardware, so use the appropriate IDE and hardware, and it'll work fine.

    The Raspberry PI can be used for alot of things, but not DCC++. The RPI can easily be used as a JMRI computer to control the DCC++ system, or almost any other DCC system.
     
  4. rdkdrn

    rdkdrn New Member

    6
    1
    1
    Darken, yes the header file is there and I have built several of the examples and deployed them to the uno with success.

    Crusader27529, the raspberry pi is used to run the IDE and eventually JMRI, I have an UNO to run the sketch on. I am very familiar with the Raspberry Pi, no issues there.
     
  5. drken

    drken TrainBoard Member

    344
    200
    19
    OK, I wasn't sure how familiar you were with Arduinos. If other sketches are currently working, it's probably not the IDE itself. But, try reinstalling the Arduino IDE and the DCC++ sketch anyway as that's generally a good idea for any wonky sketch. Besides the Arduino IDE undergoes semi-frequent updates but does not update automatically or notify you like the Libraries and Board drivers do, so it's a good habit to get into. Also, which operating system are you using on the RasPi? I've had issues with getting the Arduino to work with Rasbian, but got it to work fine with Ubuntu Mate.
     
  6. rdkdrn

    rdkdrn New Member

    6
    1
    1
    This is a new install of the IDE on a newly updated pi (raspian) so everything is the latest available.
     
  7. rdkdrn

    rdkdrn New Member

    6
    1
    1
    After more digging I found out that the version of the IDE is old on the Pi and will not be updated. So I moved DCC++ over to my windows 10 PC and got it compiled, but now I cannot get the driver loaded on Windows 10. Any ideas?
     
  8. drken

    drken TrainBoard Member

    344
    200
    19
    What do you mean "the driver"? The Processing program? There's a version for 64 bit Windows on the Processing.org site
    https://www.processing.org/download/
     
  9. rdkdrn

    rdkdrn New Member

    6
    1
    1
    I was talking about the serial drivers for the device, but I worked around my problems and things are working now.
     
    drken likes this.
  10. John W Zerbe

    John W Zerbe TrainBoard Member

    96
    59
    7
    If you are still interested in using the Pi, I recommend downloading the Linux ARM version of the arduino ide to the pi and don't use the one that you can install with Raspian. I have my Pi 3 connected to my Arduino Mega via usb and use VNC to access its desktop from my main windows machine for accessing jmri on that machine.
     
  11. rdkdrn

    rdkdrn New Member

    6
    1
    1
    Thanks John, actually I have a 6 node Pi cluster that I use for various things. I will definitely try it, once again thanks.
     

Share This Page