Hi. I currently run my openremote controller on ubuntu, and really want to be able to run it on something very light weight like a router or raspberry pi type device.
Is it possible to run openremote on an optware enabled dd-wrt router? I haven't seen any java releases for it so I doubt it.
The controller is a regular webapp which should run on any JEE app server.
We already tested the controller on Raspberry Pi and that works quite well.
Some NAS systems were reported to work and we also recommend the PC engines ALIX board.
Posted by mredeker at May 25, 2012 22:52
Ok - great. I've been banging my head against the wall all afternoon trying to get tomcat to run on my router, of course I keep getting out of memory errors. I setup jamvm and tomcat, but never got it to start.
What app server would you recommend for a MIPS platform running optware? I have seen a few lightweight options like jetty and winstone but haven't tried them.
Any assistance in this area would be greatly appreciated!
Posted by salesguy at May 25, 2012 23:01
I am not sure if jamvm and tomcat work together. If you can report a success, that would be great
Unfortunately I cannot be of any help in the area of optware. I never used it or tried to run Java on it.
Posted by mredeker at May 25, 2012 23:06
Well, i'm trying really hard, but nothing yet.
If you were starting out fresh on a openwrt type platform - stripped down linux, what would you use for a jvm? Which app server would you use as an alternative to tomcat?
Posted by salesguy at May 25, 2012 23:10
Sorry, I cannot give any hint on java or app servers on openwrt.
Posted by mredeker at May 25, 2012 23:12
Ok, for anyone interested, I finally got tomcat to start without fatal errors, but it immediately crashed when a page request was made. So I give up on this little project.
Marcus - if you can provide some details on how you setup the controller on the raspberry I'd appreciate it.
Posted by salesguy at May 26, 2012 23:27
Too bad Here in Germany a lot of people have the AVM Fritzbox and it would be nice to have OpenRemote running on that one.
You can only get the jamvm for that box but I guess tomcat is out of the picture.
Setting up the controller on Raspberry Pi is easy. The default OpenJDK that comes with the debian "squeeze" image is bad in performance though. The IcedTea cacao VM is much better. But that one has a threading problem with debian "squeeze". So I took the debian "squeeze" image from the Raspberry website and changed the "/etc/apt/sources.list" to point to the "wheezy" distro.
I then installed OpenJDK JRE and IcedTeac-Cacao-CM from wheezy.
Tomcat runs fine with that.
Posted by mredeker at May 28, 2012 09:44
Is it possible to controller directly support GPIO ports on Raspberry Pi?
Posted by damirvk at Jun 06, 2012 13:40
Using the "/sys/class/gpio/" driver you can access the GPIO subsystem using regular Java file I/O.
Here (http://hobbyelektronik.org/w/index.php/Raspberry_Pi_IO) you can find some information on how to turn on/off some Led's attached to the Pi using PHP.
You can use Google translate to turn this into english
Posted by mredeker at Jun 06, 2012 15:13
lol, does sound like is written on some strange language.
Is there a chance that will be supported directly in online designer?
Posted by damirvk at Jun 07, 2012 23:21
Well it's written in german You can translate with Google if you are interested.
Supporting the GPIO of the Pi is nothing that is planned in the moment.
Posted by mredeker at Jun 08, 2012 09:05
Than google translate work very well, to me when translating from some language to Croatian usually result is junk.
My plan is to run ORB on Pi, so it would bi a good thing to have few I/O pins directly on device. If I manage to get this working and when you finish support for z-wave all I need is there.
tnx for answers.
Posted by damirvk at Jun 09, 2012 09:19
I have installed the controller on my new Raspberry pi and it works 100% faster then on my Synology. It was very slow on my Synology, but with the new Oracle "ejre-7u6-fcs-b24-linux-arm-vfp-client_headless-10_aug_2012.tar.gz", it works really good!
I have used this tutorial for installing Java.
Posted by dlowet at Aug 27, 2012 19:59
I too have OR Controller running on my Pi. (Almost) successfully.
It installs fine and works alongside either IcedTea (Cacoa JVM) or Oracle JVM. Either seems ok.
I followed the instructions here
There does seem to be a problem though when trying to use a Designer file with lots of panels, or lots of pages with graphics on several panels. I haven't gotten to the bottom of it yet, but it may be that the Pi is running out of memory. I can get it working perfectly by creating a new account and having a very basic Designer panel with a couple of buttons. However my primary Designer Account with lovely graphical panels doesn't work and complains "Cannot Get Panel List" - despite working fine when OR Controller is running on my PC.
Posted by mbarne36 at Sep 17, 2012 09:19
Do you see any exceptions in any of the log files on the controller?
Posted by mredeker at Sep 17, 2012 14:49
That's a good question - but alas I do not know.
I will take a look tonight.
Posted by mbarne36 at Sep 17, 2012 14:56
Hi Marcus (everyone)
Joy.... I have a log file.
So. Two experiments. First up, I loaded the "simple" designer files to the Pi (the one with one panel, one layout and one button). I ran up my Pi and connected to my android tablet. On the Pi, I looked in the Logs directory and saw that the log files had been created, but they were all empty.
Then, I downloaded using WinSCP the more complex designer files with multiple panels and layouts and did the same. Reboot, check the logs, and voila, I have a log in Catalina.2012-09-17 with the following entry;
Sep 17, 2012 6:12:50 PM org.apache.catalina.session.StandardManager doLoad
SEVERE: IOException while loading persisted sessions: java.io.EOFException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
Now, a much more edumacated person than me needs to translate this, but what I must add is that this designer file seems to work fine when the controller is running on a PC.
So... what do you think noble community. Please help. Obviously the word "SEVERE" doesn't fill me with great confidence.
Posted by mbarne36 at Sep 17, 2012 19:24
This is actually an error related to Tomcat's session persistency which we don't even need.
You can try and turn it off. Look at the file controller-2.0.x/conf/context.xml
All the way to the top you see a command about session persistence see. Try and uncomment as mentioned there.
Posted by mredeker at Sep 17, 2012 19:31
Thanks Marcus. I removed the error using your suggestion.
However, the problem still occurs. That is when loading a panel on my tablets, i get an error "Using Cached Content", "Current Controller isn't available".
I have been doing some tests....
I stripped down my existing designer files and started adding back screens. I added eight screens back in until the error occurred. At this point the zip of my designer files was 1.6M.
So - is there some memory or processing limitation on the Raspberry Pi that prevents using panel designer files >= 1.6M ? A bit of research reveals that I should have over 256MB of memory on my Pi so surely not a memory problems ...
(don't forget these files works flawlessly on my PC Controller).
Looking forward to any help out there....
Posted by mbarne36 at Sep 26, 2012 18:03
... bit more info....
Raspberry Pi seems to think that it has 42M memory free (according to "free -m").....
Me very confused.....
Posted by mbarne36 at Sep 26, 2012 18:32
maybe this will help.... http://www.raspberrypi.org/archives/2180
The new raspberry pi models have 512MB
oh well time to buy another
Posted by banditkd at Oct 16, 2012 13:21