Author Topic: After troubleshooting, Zelda continues to crash to homescreen  (Read 5046 times)

Offline adjoiningPanda

  • bit
  • Posts: 5
    • View Profile
After troubleshooting, Zelda continues to crash to homescreen
« on: February 24, 2012, 12:01:56 PM »
First of all, I want to say that I've been admiring the substantial progress this app has made in the last couple of months. A big thanks to Paul and supporting developers.

Now to my problem: I've tried load both Zeldas with multiple different settings, but the furthest I can get is creating a save. Sometimes I don't even get that far. The app then closes to the homescreen with the notification in the notification bar. However, this only seems to be happening with Zelda. I've tried Banjo-Kazooie and Super Mario, and they both work fine; no crashes.

I've already checked the "Troubleshooting crash to menu" topic, and nothing seems to help. The games are in z64 format, I've tried restoring the app data, and OpenGL 2.0 is supported.

I'm on the original Motorola Milestone running CM7.1.2

Thanks for the help :)

Offline Paul

  • Administrator
  • double
  • *****
  • Posts: 3499
  • Developer
    • View Profile
    • PaulsCode.Com
Re: After troubleshooting, Zelda continues to crash to homescreen
« Reply #1 on: February 24, 2012, 02:18:37 PM »
Could you try enabling/ disabling Tribuffer Opt in the video settings (for gles2n64)?  Also try changing to the gles2rice video plug-in to see if it still crashes.  If none of those help, I'll put together a test for you to run to try and get some useful debug information on what's causing the crash.
Device: Samsung Galaxy Nexus i515
CPU: TI OMAP4460, 1.2 GHz (dual core, ARM Cortex-A9)
GPU: PowerVR SGX540, 307 MHz
RAM: 1 GB
Resolution: 720 x 1280
Rom: omni-4.4.4-20141014-toro-FML KitKat 4.4.4, rooted

Device: Eee PC 1015PEM
CPU: Intel Atom N550, 1.5 GHz (dual core, x86)
GPU: Intel GMA 3150, 200 MHz (dual core)
RAM: 2GB
Resolution: 1024 x 600
Rom: android-x86-4.3-20130725 Jelly Bean 4.3, rooted

Offline adjoiningPanda

  • bit
  • Posts: 5
    • View Profile
Re: After troubleshooting, Zelda continues to crash to homescreen
« Reply #2 on: February 24, 2012, 03:17:55 PM »
Still crashes  :-\

Offline Paul

  • Administrator
  • double
  • *****
  • Posts: 3499
  • Developer
    • View Profile
    • PaulsCode.Com
Re: After troubleshooting, Zelda continues to crash to homescreen
« Reply #3 on: February 24, 2012, 03:35:58 PM »
Ok, please run the following debug build, and post the logcat output:

Test APK

If you aren't familiar with accessing the logs, see this thread.
Device: Samsung Galaxy Nexus i515
CPU: TI OMAP4460, 1.2 GHz (dual core, ARM Cortex-A9)
GPU: PowerVR SGX540, 307 MHz
RAM: 1 GB
Resolution: 720 x 1280
Rom: omni-4.4.4-20141014-toro-FML KitKat 4.4.4, rooted

Device: Eee PC 1015PEM
CPU: Intel Atom N550, 1.5 GHz (dual core, x86)
GPU: Intel GMA 3150, 200 MHz (dual core)
RAM: 2GB
Resolution: 1024 x 600
Rom: android-x86-4.3-20130725 Jelly Bean 4.3, rooted

Offline adjoiningPanda

  • bit
  • Posts: 5
    • View Profile
Re: After troubleshooting, Zelda continues to crash to homescreen
« Reply #4 on: February 24, 2012, 08:25:34 PM »
There you go, Paul. I really appreciate the time you're taking to do this.

Offline Paul

  • Administrator
  • double
  • *****
  • Posts: 3499
  • Developer
    • View Profile
    • PaulsCode.Com
Re: After troubleshooting, Zelda continues to crash to homescreen
« Reply #5 on: February 24, 2012, 09:07:28 PM »
Hmm, that's weird.  It actually doesn't actually appear to crash -- the app just shuts down:

Code: [Select]
I/ActivityManager( 2051): Process paulscode.android.mupen64plus.test (pid 2874) has died.
I/WindowManager( 2051): WIN DEATH: Window{4079dd90 paulscode.android.mupen64plus.test/paulscode.android.mupen64plus.SDLActivity paused=false}

Those are normal messages you'd expect to see when the app shuts down.  I don't see anything obvious in the log that could be indicating what is actually causing the app to shut down, though.

The only theory I can think of, is there are a lot of messages about low memory in there:
Code: [Select]
I/ActivityManager( 2051): Low Memory: No more background processes.
And several background processes are getting shut down.  One thing that caught my eye is an error about the sensor service (which Mupen64Plus connects to via the SDL port, even though it isn't being used by the emulator itself):

Code: [Select]
E/SensorService( 2051): dropping 1 events on the floor (Broken pipe)
This happens right before the line that says mupen64plus died.  The error messages that follow are about a broken input channel:
Code: [Select]
E/InputDispatcher( 2051): channel '4079dd90 paulscode.android.mupen64plus.test/paulscode.android.mupen64plus.SDLActivity (server)' ~ Consumer closed input channel or an error occurred.  events=0x8
E/InputDispatcher( 2051): channel '4079dd90 paulscode.android.mupen64plus.test/paulscode.android.mupen64plus.SDLActivity (server)' ~ Channel is unrecoverably broken and will be disposed!

I'll see if there is a way to disconnect SDL from the sensor to see if that helps.  I don't really know why the sensor would be shutting down, other than the device ran out of memory.  In the mean time, you might try rebooting your device immediately before running the emulator (in case another running process has a memory leak).  If you have a task manager app installed, you might also try shutting down any background processes that you don't need, to try and free up some more memory.  You could also free up a little bit of memory if you disable the audio plug-in (but you won't hear any sound) -- might be worth trying to see if it prevents the crash from happening.
Device: Samsung Galaxy Nexus i515
CPU: TI OMAP4460, 1.2 GHz (dual core, ARM Cortex-A9)
GPU: PowerVR SGX540, 307 MHz
RAM: 1 GB
Resolution: 720 x 1280
Rom: omni-4.4.4-20141014-toro-FML KitKat 4.4.4, rooted

Device: Eee PC 1015PEM
CPU: Intel Atom N550, 1.5 GHz (dual core, x86)
GPU: Intel GMA 3150, 200 MHz (dual core)
RAM: 2GB
Resolution: 1024 x 600
Rom: android-x86-4.3-20130725 Jelly Bean 4.3, rooted

Offline adjoiningPanda

  • bit
  • Posts: 5
    • View Profile
Re: After troubleshooting, Zelda continues to crash to homescreen
« Reply #6 on: February 25, 2012, 12:20:06 AM »
Rebooting gave me 20 more seconds of gameplay, but that's the extent of it. Disabling audio and killing apps didn't really seem to work either.

Is it a RAM problem? The Super Mario and Banjo-Kazooie files are 8mb and 16 mb respectively, while Zelda is 32mb. Is it just too big of a file for my phone to handle?

Offline Tom.K

  • Green Team
  • long
  • *
  • Posts: 130
    • View Profile
Re: After troubleshooting, Zelda continues to crash to homescreen
« Reply #7 on: February 25, 2012, 03:18:03 AM »
That phone has about 256 mb, while mine has about 128 MB of RAM with 256 MB swap and 26% compcache. I have to say that it is a RAM problem as I have similar problem when I just ran OOT, it closed on beginning of game, after loading save, similar thing with MM, but I can play only on first area of forest, when I go to small wood tunnel, it closes (noticed that it's a known bug).

I'm not sure is your phone capable to include options for memory optimization. As far I've noticed, here's a bigger problem... Milestone still doesn't have option to have unlocked bootloader, so you can't have optimized kernel to make your phone more smooth, not even to get swap, not sure about compcache.

Try to use this ROM Toolbox ( https://market.android.com/details?id=com.jrummy.liberty.toolbox&hl=en ) and go to "Performance > Auto Memory Manager" and try to set preset to Aggressive or try different presets, but don't set it to boot unless you think it's safe to do it.

Offline adjoiningPanda

  • bit
  • Posts: 5
    • View Profile
Re: After troubleshooting, Zelda continues to crash to homescreen
« Reply #8 on: February 25, 2012, 04:46:28 PM »
It seems what Tom proposed has worked. I messed with the settings and it seems like the higher i set the "Foreground Application" setting, the faster the emulator closes. However, when I set the foreground application lower than 6mb (default), the emulator seems to run much longer without crashing. Performance seems to take a hit, though. Any reason as to why this is?

Offline Paul

  • Administrator
  • double
  • *****
  • Posts: 3499
  • Developer
    • View Profile
    • PaulsCode.Com
Re: After troubleshooting, Zelda continues to crash to homescreen
« Reply #9 on: February 26, 2012, 10:44:58 AM »
I'll see about reducing the memory foot print to see if that helps.  I have a couple ideas I'll try in this upcomming update (moving things around so I don't have to load as many native libraries on the Java side of the house)
Device: Samsung Galaxy Nexus i515
CPU: TI OMAP4460, 1.2 GHz (dual core, ARM Cortex-A9)
GPU: PowerVR SGX540, 307 MHz
RAM: 1 GB
Resolution: 720 x 1280
Rom: omni-4.4.4-20141014-toro-FML KitKat 4.4.4, rooted

Device: Eee PC 1015PEM
CPU: Intel Atom N550, 1.5 GHz (dual core, x86)
GPU: Intel GMA 3150, 200 MHz (dual core)
RAM: 2GB
Resolution: 1024 x 600
Rom: android-x86-4.3-20130725 Jelly Bean 4.3, rooted