raymond
Posts: 2
Joined: Sun Apr 22, 2012 5:49 pm

Re: Can it run java 1.6?

Sun Apr 22, 2012 6:54 pm

As title can we run java on it?

I prefer java than python.

spurious
Posts: 343
Joined: Mon Nov 21, 2011 9:29 pm

Re: Can it run java 1.6?

Sun Apr 22, 2012 6:58 pm

I'd be surprised if it does, purely on the memory requirements.

One of the embedded Javas might

User avatar
Gert van Loo
Posts: 2487
Joined: Tue Aug 02, 2011 7:27 am
Contact: Website

Re: Can it run java 1.6?

Sun Apr 22, 2012 7:31 pm

That question has been asked before. please search the Forum.

One of the 'interesting' questions is if we can use the JAVA (Jazelle) instruction engine which is part of the ARM1176 core.

spurious
Posts: 343
Joined: Mon Nov 21, 2011 9:29 pm

Re: Can it run java 1.6?

Sun Apr 22, 2012 7:38 pm

Gert said:


That question has been asked before. please search the Forum.

One of the 'interesting' questions is if we can use the JAVA (Jazelle) instruction engine which is part of the ARM1176 core.


ooh.. I thought that had been dismissed, as we needed access to some docs and or something that enabled it.

lb
Posts: 263
Joined: Sat Jan 28, 2012 8:07 pm

Re: Can it run java 1.6?

Sun Apr 22, 2012 8:15 pm

Gert said:


One of the 'interesting' questions is if we can use the JAVA (Jazelle) instruction engine which is part of the ARM1176 core.


No, it isn't. Jazelle (DBX) is pretty useless. It's much slower than a decent VM, but (from what I've heard) complicated to implement and use, and requires licensing from ARM. I don't know of any up-to-date VM that can use Jazelle, which says a lot already. It has been abandoned on Cortex cores for good reason.

Jazelle RCT is another extension that provides more useful functions specifically for JITs, but this isn't supported by ARM11.

User avatar
mkopack
Posts: 242
Joined: Mon Nov 07, 2011 8:46 pm

Re: Can it run java 1.6?

Mon Apr 23, 2012 2:49 am

Yes, Open JDK 1.6 works.

You need to be VERY aware of the limited memory you have to work with though! Command line stuff the doesn't get too crazy with memory will work. SMALL swing apps should work. Larger stuff is going to have trouble as there just isn't enough room for a huge Heap space to allocate objects out of.

Jazelle is a non-starter - don't even bother.

You can probably forget Eclipse or Netbeans - way too large.

raymond
Posts: 2
Joined: Sun Apr 22, 2012 5:49 pm

Re: Can it run java 1.6?

Mon Apr 23, 2012 3:37 am

I want to compile java at PC and run on this board to do some networking and I/O output, is it possible?

Or i can only use C to achieve this goal?

greenwoodma
Posts: 6
Joined: Fri Mar 30, 2012 7:52 am

Re: Can it run java 1.6?

Mon Apr 23, 2012 6:28 am

You can definitely run Java 1.6 on the Raspberry Pi. I know you can because I have. You can read about what I did in a blog post I wrote: http://englishjavadrinker.blog.....ation.html

Have a look at the link in the comments to the post as well for some suggestions on how to enable hardware acceleration for any Java GUI stuff you want to run.

Michael
Posts: 340
Joined: Sat Jul 30, 2011 6:05 pm

Re: Can it run java 1.6?

Tue May 08, 2012 7:36 pm

The good news is that Oracle are working on a JDK for the Raspberry Pi.  Its early days jet, but they have already shown it running JavaFX:

http://www.i-programmer.info/n.....ry-pi.html

chrisg
Posts: 28
Joined: Wed Sep 21, 2011 6:41 pm
Location: Epsom, Surrey

Re: Can it run java 1.6?

Tue May 08, 2012 9:29 pm

Michael or anyone else who knows: do you have any more information about what Oracle are considering here?

We discussed this previously in another thread once several months ago, after I'd done some comparisons of Java on ARM running under qemu.

Now that I have a real Raspberry Pi (yay!) I've been running the DaCapo benchmark suite on a number of JVM implementations, and I'm seeing that the Oracle Embedded VM is typically around 5 times faster than OpenJDK Zero (the current Debian Squeeze version), and more reliable and supported than Cacao. I'm happy to post my results somewhere, maybe on the Wiki, if anyone is interested.

So the Oracle SE Embedded VM would appear to be a strong recommendation, except that:


The VM for ARMv6 is headless, which largely rules it out for desktop applications.
The non-free license with Java SE Embedded might be a concern for some people or some applications (anyone who needs to redistribute).

If Oracle are indeed working on a JDK for the Raspberry Pi, I assume it would need to be headful. Can you confirm this? If this is happening, do you know if it would it be licensed as a desktop VM or embedded VM, or something else?

Thanks,

Chris

Michael
Posts: 340
Joined: Sat Jul 30, 2011 6:05 pm

Re: Can it run java 1.6?

Tue May 08, 2012 9:42 pm

Hi Chris,

I'd suggest trying to ping Simon Ritter at Oracle, see if he has any further details he can currently share but I would guess it is a case of biding your time as I don't think they are quite ready to announce.

https://twitter.com/#!/@speakjava

https://blogs.oracle.com/speakjava/

mredeker
Posts: 8
Joined: Tue Jan 31, 2012 12:54 pm

Re: Can it run java 1.6?

Fri May 18, 2012 9:07 pm

Using the debian image and updating to "wheezy" the OpenJDK with IcedTeat cacao runs without any problems.
I have Tomcat and the OpenRemote controller running on it without any problems.

The "cacao" VM performs much better then ZeroVM but it has a bug in debian "squeeze". That's why you need to update to "wheezy".

TeamMCS
Posts: 2
Joined: Tue Feb 21, 2012 10:04 pm

Re: Can it run java 1.6?

Sat May 19, 2012 8:41 am

You may want to check out my post for the Pogoplug which shows Tomcat running.

It's pretty simple to get Java running, you just have to be a bit flexible on memory:

http://www.milesburton.com/Pogoplug_Pro ... g_Tomcat_6

User avatar
fulburncams
Posts: 70
Joined: Wed Nov 30, 2011 8:29 pm

Re: Can it run java 1.6?

Mon May 21, 2012 5:25 pm

Hi
I am running OpenJDK and it seems to work fine but only tried small graphics and text based apps so far. My goal is to run it as a small server so no graphics on the Raspi, just serving applets to clients. Currently struggling with JNI to get access to GPIO via C examples on the Wiki. I use Netbeans on a PC and then FTP .class files/or Jar's accross to Raspi.
Regards
Steve

User avatar
freedomotic
Posts: 154
Joined: Sat Apr 21, 2012 3:59 pm
Location: Italy
Contact: Website

Re: Can it run java 1.6?

Sun Jul 15, 2012 8:40 am

fulburncams wrote:Hi
I am running OpenJDK and it seems to work fine but only tried small graphics and text based apps so far. My goal is to run it as a small server so no graphics on the Raspi, just serving applets to clients. Currently struggling with JNI to get access to GPIO via C examples on the Wiki. I use Netbeans on a PC and then FTP .class files/or Jar's accross to Raspi.
Regards
Steve
Hi Steve,
we are trying to use raspi with openjdk 1.6 to serve a war file with jetty server for a gwt client. But it is very slow. We tried the trial version of oracle embedded vm and it's much faster. So do you know some tips to improve the performance of openjdk vm?
Thanks
Freedomotic Open IoT Framework
http://freedomotic.com

Return to “General discussion”