1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Raspberry Pi 3

Discussion in 'General Discussion' started by Golkiwu, Aug 27, 2016.

  1. Golkiwu

    Golkiwu Member

    Joined:
    Sep 7, 2010
    Messages:
    360
    Likes Received:
    5
    Greetings,

    I am requesting any assistance on getting D20PRO to run on Raspbian. I have about 6 weeks of experience with Linux, so I know what I can google, and on this, it ain't much.

    I have Java 7 installed, and the Linux install folder for D20PRO unzipped to my Desktop.

    That is far as I can get. Total NOOB. I don't even know the command line to try.

    Thanks, for any assistance. This is just a test project so no biggie if is not doable.
     
  2. owlbear

    owlbear Administrator
    Staff Member

    Joined:
    Sep 5, 2011
    Messages:
    574
    Likes Received:
    151
    Hi Golkiwu. Just a quick note about having seen but not fully processed your request.

    Keep in mind my experience with the linux side of D20PRO is fairly limited as well. Thraxxis and the other Mindgene team members did a great job of building our installers such that I have extremely high confidence of builds working in the linux environment, however, there are some known issues which need adddressing.

    Some of these should be fixed as part of the major release slated for next week. All of the current outstanding issues are related to line endings in the launcher scripts.

    Supplying you can correct the lineending issue before we release a rebuilt zip, you'll need to satisfy a fairly small dependancy list to use D20PRO.

    The core of this list (and a nice way to in directly include the other reqs) is to simply say, a working x-windows envrionment.
     
  3. edwardcd

    edwardcd Administrator
    Staff Member

    Joined:
    Oct 13, 2010
    Messages:
    1,374
    Likes Received:
    9
    Usually, Linux flavors tend to lean towards OpenJDK/JRE for the Java implementation, please find out what Java you have, if it is OpenJDK/JRE we will need to remove that and install SunJDK/JRE.

    The file encoding is sometimes off for d20pro.sh (which is what you'll use to open d20pro). You can see what condition it is in when you attempt to run d20pro.sh, if you get a text editor, it's the wrong encoding - and will need to fix it. If it launches d20pro - great!

    If someone can point me to an ISO version of Raspbian I can create a virtual machine and test this flavor. (all I'm able to find is the IMG file version, and don't feel like burning a cd then capturing its image into an ISO - as the IMG file doesn't like to convert with the tools I have :( )
     
  4. owlbear

    owlbear Administrator
    Staff Member

    Joined:
    Sep 5, 2011
    Messages:
    574
    Likes Received:
    151
    Not to mention managing permissions. You'll need to chmod the d20pro.sh to allow execution. If this is a new concept to you I would be doing you a disservice by giving you a simple answer. More than likely you have the man command at you disposal - try man chmod
     
  5. Golkiwu

    Golkiwu Member

    Joined:
    Sep 7, 2010
    Messages:
    360
    Likes Received:
    5
    I literally don't even know how to make it run. There was some long line in the Read Me file but running it in command line did nothing. What I really need to start, is to know how to tell it to try to run. Like I said. Total. NOOB.
     
  6. edwardcd

    edwardcd Administrator
    Staff Member

    Joined:
    Oct 13, 2010
    Messages:
    1,374
    Likes Received:
    9
    Okay. Looks like after some digging, Rasbian Jesse uses Debian Jesse with the lxde gui. So, I'll get that in the virtual machine and get you some steps. :)
     
  7. edwardcd

    edwardcd Administrator
    Staff Member

    Joined:
    Oct 13, 2010
    Messages:
    1,374
    Likes Received:
    9
    Opening Terminal..
    (in my case I did from (start) > Debian > Applications > Shells > Bash)
    debian_step2_verifyJavaVersion1.jpg

    Finding my Java Version
    Code:
    java -version
    Result:
    java version "1.7.0_101"
    OpenJDK Runtime Environment (IcedTea 2.6.6) (7u101-2.6.6.2~deb8u1)
    OpenJDK 64-Bit Server VM (built 24.94-b01, mixed mode)
    debian_step2_verifyJavaVersion2.jpg

    Finding my Java Packages
    Code:
    sudodpkg --list | grep -i jdk
    Result:
    openjdk-7-jre:amd64
    openjdk-7-jre-headless:amd64
    debian_step2_verifyJavaVersion3.jpg

    Deleting my non-Sun Java Packages (I have two)
    Code:
    sudo apt-get purge openjdk-7-jre:amd64
    Result: Removed default-jre and openjdk-7-jre
    debian_step2_DeleteOpenJDKJava4.jpg
    Code:
    sudo apt-get purge openjdk-7-jre-headless:amd64
    Result: Removed other java openjdk7 references

    Housekeeping (goto directory /usr) THEN make directory java, THEN go into /usr/java
    Code:
    cd /usr

    Code:
    mkdir java

    Code:
    cd java

    debian_step4_housekeeping.jpg

    Download Sun/Oracle Java
    Code:
    wget --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie"  http://download.oracle.com/otn-pub/java/jdk/8u101-b13/jdk-8u101-linux-x64.tar.gz
    debian_step3_downloadTarGZ.jpg


    Install Java

    Code:
    tar zxvf jdk-8u101-linux-x64.tar.gz
    After pressing enter, you will see the install running, and should see the following:
    debian_step5_afterInstall.jpg
    Manually set variables:
    export JAVA_HOME=/usr/java/jdk1.8.0_101
    export PATH=$PATH:/usr/java/jdk1.8.0_101/bin
    debian_step6_manualSetJava.jpg

    Set Java Alternatives
    Code:
    update-alternatives --install "/usr/bin/java" "java" "/usr/java/jdk1.8.0_101/bin/java" 1
    Code:
    update-alternatives --install "/usr/bin/javac" "javac" "/usr/java/jdk1.8.0_101/bin/javac" 1
    Code:
    update-alternatives --install "/usr/bin/javaws" "javaws" "/usr/java/jdk1.8.0_101/bin/javaws" 1

    Set Java Options
    Code:
    export _JAVA_OPTIONS="-Xms1024m -Xmx1024m"
    Run D20PRO
    first locate directory (mine is /home/curtis/Documents/D20PRO-3.6.8/ )
    Code:
    java -jar D20PRO.jar
    debian_step7_run1.jpg
     

    Attached Files:

    #7 edwardcd, Aug 30, 2016
    Last edited: Aug 30, 2016
    Robotguy likes this.
  8. edwardcd

    edwardcd Administrator
    Staff Member

    Joined:
    Oct 13, 2010
    Messages:
    1,374
    Likes Received:
    9
    and waaaalaaaa...
    debian_step7_run2.jpg

    debian_step7_success.jpg
     
    Robotguy likes this.
  9. Golkiwu

    Golkiwu Member

    Joined:
    Sep 7, 2010
    Messages:
    360
    Likes Received:
    5
    WOW Awesome response. It will be next week before I can get into this, but thanks for all the instruction! I almost wish I had started this project a couple of months ago. I could be packing some monitors and a handful of Pi3's to con instead of a suitcase of laptops for DragonCon.
     
  10. Robotguy

    Robotguy Member

    Joined:
    Oct 10, 2013
    Messages:
    89
    Likes Received:
    3
    That was a really great step-through! I may have to give it a try. How's the performance?
     
  11. Golkiwu

    Golkiwu Member

    Joined:
    Sep 7, 2010
    Messages:
    360
    Likes Received:
    5
    They were running it on a Virtual Machine so not sure. I have yet to work on it myself, convention coming up. I hope to report in a week or 2 on it with the Pi3.
     
  12. Ken L

    Ken L Member

    Joined:
    Dec 13, 2015
    Messages:
    90
    Likes Received:
    0
    I hate to be the spoiler, but there is no Java FX package for ARM. Another user tried to do this with ra-pi 2 rev B and discovered this when getting the appropriate java JRE.

    AMD64 != ARM64

    That should have been obvious, I work with low level hardware drivers and OS optimization. When you work in lofty high-level languages, you kinda forget that in the end, the mirco code at the hardware level still needs the match up and is a factor.
     
    #12 Ken L, Aug 31, 2016
    Last edited: Aug 31, 2016
  13. edwardcd

    edwardcd Administrator
    Staff Member

    Joined:
    Oct 13, 2010
    Messages:
    1,374
    Likes Received:
    9
    So true..

    The current rpi3 (when installed with Raspbian Jessie) comes with Oracle Java 8u65, which does open D20PRO. However, you won't get past the D20PRO Live /Splash Screen or be able to host or connect to any game (sure, the GM will see you connect then disconnect a few seconds later - when your rpi3 is trying to display the main D20PRO screen).

    rpi3_d20pro_startup.jpg

    Oracle removed JavaFX on ARM and Java SE Embedded starting with 1.8.0_33 (aka 8u33).

    Thus, I've attempting to recreate an earlier version of Oracle's Java 8u6, though I still receive an Unexpected throwable initializing app java.lang/NullPointerException Error when connecting to a server and when trying to host.

    rpi3_d20pro_error.jpg

    There are ways to get JavaFX with cross-compiling in the OpenJFX world, but it's unlikely that will work.
     
  14. owlbear

    owlbear Administrator
    Staff Member

    Joined:
    Sep 5, 2011
    Messages:
    574
    Likes Received:
    151
    Hi all, regarding running D20PRO on a Pi3, I'm working on it. I've got pi3 hardware in hand now and will try to debug the javafx errors over the weekend -- this isn't super high priority.

    If you want to replace openjfx with oracles java8, you'll need to follow this guide:

    https://linoxide.com/debian/install-java-8-debian-gnulinux-9-stretch/

    I ran this process last night without much difficulty. For those unfamiliar with linux/unix, you'll need to add a sudo before the apt commands in the guide.
     
  15. owlbear

    owlbear Administrator
    Staff Member

    Joined:
    Sep 5, 2011
    Messages:
    574
    Likes Received:
    151
    So getting closer but still not quite there yet. The main hold up on the pi now is javafx. jfx on raspbian is very very difficult to get running correctly -- apparently.
     

Share This Page