This page last changed on Aug 24, 2014 by gheinert.

The Android Console 2.1.0 beta crashed on some, but not all Android Devices with a large design. The Logcat console revealed many "Out of memory" errors for the VM heap. On the Android devices, where the App crashed the heap size was much smaller (64M)compared to the other devices (80M).

The solution for this was to root the Android device, then use "Build Prop Editor" to edit Build.prop. Increasing the dalvik.vm.heapsize and dalvik.vm.heapgrowthlimit to 80M solved the problem. If you have a larger design this value may need to be even larger.


Hi,

Good to see that you found a solution to the problem you were experiencing, not many people would resort to rooting their phone to get around it.

I believe this is a problem related to bitmap image resources not being correctly disposed (Android handles bitmaps in unmanaged code); I had a quick attempt at fixing this problem and a compiled version is available at: -

https://www.dropbox.com/s/soluda4jsx3r8cq/Android_Console_2_1_1.apk?dl=0

Posted by kurrazyman at Aug 26, 2014 18:21

Richard, is this the final 2.1.1 that we discussed quite a while ago? Can I safley replace my 2.1.1-beta with this one?
Pieter

Posted by pz1 at Aug 27, 2014 08:26

Hi Pieter,

This is probably the same as what you installed a while ago...still haven't got the key to sign the app in order to update Google Play

Posted by kurrazyman at Aug 27, 2014 17:05

Dear Richard,

Yes, it is definitely a problem with the handling of the bitmaps. The error comes mostly from image.util: createfrompathquietly. Sometimes also from ScreenView. There is a suggestion that it can be solved by setting the bitmap to null and then calling system.gc() to clean the garbage bin. I tried this, but it has only reduced the number of error messages, but hasn't quite stopped the app crashing.

Thanks for the apk. I've tried it today on an Archos Titanium tablet, Android Version 4.1.1. But it always crashes after reading the resources for the panel. ADB Logcat reveals the following error message:

E/AndroidRuntime(2750): FATAL EXCEPTION: main
E/AndroidRuntime(2750): java.lang.RuntimeException: Unable to start activity ComponentInfoorg.openremote.android.console/org.openremote.android.console.GroupActivity: java.lang.NullPointerException
E/AndroidRuntime(2750): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2059)

Best wishes

Gideon

Posted by gheinert at Aug 27, 2014 20:52

Hi Gideon,

If you can send me a zip of your designer I can look at the exception you are seeing. The Android App needs a major overhaul rather than the occasional band aid.

Rich

Posted by kurrazyman at Aug 27, 2014 20:55

Hi Rich,

Although the 2.1.0 beta appears very stable, had it run for weeks on a wall mounted Android panel without any problem.
Sure I can send you a zip of my design. What's your e-mail address?

Tried it this morning also on a Samsung Galaxy S4 Mini Android 4.2.2. Same thing happened.
It may well be because my design is quite big.

Best wishes

Gideon

Posted by gheinert at Aug 28, 2014 10:39

Hi Gideon,
just out of interest, do you have some screenshots from your design, if that is something you would like to share?
Regards,
-Marcus

Posted by mredeker at Aug 29, 2014 07:43

Hi Marcus,

Here are some screenshots of the design - mainly KNX, 1-wire, fingerprint door entry system. There also some webcams embedded into the Openremote Design. There are about 400 commands, and a lot of Drools Rules. There also a heated dogshed with a Webcam.

Posted by gheinert at Nov 28, 2014 21:54

Hi Rich,

Can you send send me your e-mail address to openremotegh@outlook.com.
I can then e-mail you a link to download the design from my server. The design is 15MB, so too big to e-mail....

Best wishes

Gideon

Posted by gheinert at Nov 28, 2014 22:04

Hello Marcus

I have the same problem .i am using te App on a costumized Galaxy 2 10.1" with Android 4.4.4. And i am Shingen it on a Galaxy tab 3 8" With android 4.4.2 .

The icons are scaled on te Galaxy tab 2 but appear correct on te galaxy tab 3

Ive made a design Sith 1280*800 resolution which is acceptabele by both tabs.
But sometimes it suddenly crashes ,could you game a look at it?

I have made 3 panels

  • portrait 1280*800
  • landscape 1280*800 which is nog finished het because im trying tot copy the portrait version
    To a landscape tot prevent any errors or crashes nut i found out that it makes nO difference
  • korte zit format for Sony experia z phone which works without crashing

I could send you my zip file its about 3 mb

Posted by robnas at Jan 04, 2015 17:10

I cannot help with the Android console, sorry. I was just interested in the design to have something to show to others

Posted by mredeker at Jan 04, 2015 18:10

Richard could you help?

I have the same problem .i am using te App on a costumized Galaxy 2 10.1" with Android 4.4.4. And i am Shingen it on a Galaxy tab 3 8" With android 4.4.2 .

The icons are scaled on te Galaxy tab 2 but appear correct on te galaxy tab 3

Ive made a design Sith 1280*800 resolution which is acceptabele by both tabs.
But sometimes it suddenly crashes ,could you game a look at it?

I have made 3 panels

  • portrait 1280*800
  • landscape 1280*800 which is nog finished het because im trying tot copy the portrait version
    To a landscape tot prevent any errors or crashes nut i found out that it makes nO difference
  • korte zit format for Sony experia z phone which works without crashing

I could send you my zip file its about 3 mb

Posted by robnas at Jan 04, 2015 18:17

Hi Rob,

This seems to be a different problem to the one I had. I found that with large designs the App crashed during startup. This problem was solved by rooting the android device and increasing the VM heap size.

Best wishes

Gideon

Posted by gheinert at Jan 05, 2015 11:25
Document generated by Confluence on Jun 05, 2016 09:29