NextPVR Forums

Full Version: nDroid hangs on phone
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I have just sent a "report" to Google? The client does a download and then says "populating database" and that ends with "Unfortunately nDroid has stopped". Are there too many recordings in my database? The nDroid folder is at https://www.dropbox.com/s/wh7om7q6oq7b00...ervice.zip. Thanks.
Your crash report hasn't shown up on my Android Developers Console yet but I dropped your data folder into my nDroid Service folder to test it.

Try editing your npvr config.xml with Notepad and change this line...
Code:
<EPGUpdateHour>None</EPGUpdateHour>
...to have a number between 0 and 23 instead of None.

Restart the nDroid Service so it regenerates the zip files and try the nDroid app again.

Cheers,
Brian
bgowland Wrote:...to have a number between 0 and 23 instead of None.
Changed <EPGUpdateHour>. Rebooted 'puter. Uninstalled and re-installed nDroid on phone. Checked Username and password in NEWA, nDroid service and nDroid app. Rebooted 'puter. Symptoms are the same nDroid hangs on "Populating Database". Sent another Report.

I had nDroid working a month or so ago using the previous version of nDroid and the previous version of NextPVR and it would have had <EPGUpdateHour> = None (cos I do EPG updates manually using a batch file)

And finally, is <EPGUpdateHour> now obsolete having been superseded by <EPGUpdateTime>03:42:00</EPGUpdateTime> plus I still have <EPGUpdateEnabled>false</EPGUpdateEnabled> plus nDroid says that it downloads data and nDroid says that it unpacks data. Thanks.

Edit: Does nDroid store logs and stuff on the phone? I might be able to get at that if I knew where to look.
Graham Wrote:I had nDroid working a month or so ago using the previous version of nDroid and the previous version of NextPVR and it would have had <EPGUpdateHour> = None (cos I do EPG updates manually using a batch file)
I've got both of your error reports now and they're both showing the SQLite database is locked at some point - I'll need to investigate further.

That error isn't what I saw and the only thing which caused a problem was the <EPGUpdateHour> being set to None - when I changed your config.xml to have a number, your data imported without a problem. To be honest I'm surprised if it ever worked when it was set to None as the config.xml parsing code in nDroid expects a number and throws an unhandled exception with "None".

Quote:And finally, is <EPGUpdateHour> now obsolete having been superseded by <EPGUpdateTime>03:42:00</EPGUpdateTime> plus I still have <EPGUpdateEnabled>false</EPGUpdateEnabled>
Yes, <EPGUpdateHour> is obsolete with npvr v2.6.2 but the current release version of nDroid uses it for it's daily automatic updates. Both <EPGUpdateTime> and <EPGUpdateEnabled> are new to npvr v2.6.2 and I've rewritten nDroid to uses those if it finds them - it'll still use <EPGUpdateHour> though for users who still use older npvr versions and it's fixed WRT the setting being None.

Quote:Edit: Does nDroid store logs and stuff on the phone? I might be able to get at that if I knew where to look.
nDroid uses native logging to something called Logcat - it's an in-memory circular log. It can be accessed using various apps available on Google Play (I use CatLog) but I suspect you'd just see the same as what I got in your crash reports. Also, for security reasons, as of Android v4.x, Logcat isn't accessible unless your device is rooted.

I'll check your crash reports further but I'll also be uploading a new version of nDroid later so it might be worth you giving that a try when it's available.

Cheers,
Brian
Thanks for looking at this. I'll happily wait and try the next version of nDroid.

I'll skip rooting the phone. I know my luck and I fear that rooting will not end well. Have I understood my superficial reading correctly and does Android include SQLite? Can I find the database file on the phone (and would that help)?

For the avoidance of doubt ... I have never used the automatic EPG update in NextPVR. I run a batch file that includes lines like "nextpvr.exe -updateepgonly". I have updated that batch file to include the line ' sc control "nDroid Service" 129 '.
I tried to install ndroid on my nexus 4 today, Im afraid I also get the same error. Its never been installed before. My config.XML already had the epgupdatehour set to 2. Would it help to send the error report?
I take that back. I uninstalled and reinstalled for the 3rd time, but this time cleared all data and its working now:-)
Graham Wrote:Thanks for looking at this. I'll happily wait and try the next version of nDroid.
In the 2 years since I first released Android there have been 8 similar error reports so I would like to get to the bottom of it at some point. Unfortunately the people who previously submitted the reports haven't posted here on the forums and the error reports don't really give much away - I've got a slightly better idea now but still not 100% sure. I didn't get the new version uploaded last night as I wanted to some more tests but I should get it uploaded tonight.

Quote:I'll skip rooting the phone. I know my luck and I fear that rooting will not end well.
Yeah, there are risks - I've never tried it and don't really feel the need to do it.


Quote: Have I understood my superficial reading correctly and does Android include SQLite? Can I find the database file on the phone (and would that help)?
Yes, Android has native support for SQLite but the nDroid database is stored in the internal memory which is private on a per-app basis so to find it you'd need a rooted phone. I'm not sure it would help, however, as this seems to be a run-time error. I have done some reading about it and now know what conditions can cause a database lock but haven't tracked down the offending code yet.

trummel Wrote:I take that back. I uninstalled and reinstalled for the 3rd time, but this time cleared all data and its working now:-)
OK great, thanks for the confirmation.

Cheers,
Brian
Graham Wrote:... says "populating database" and that ends with "Unfortunately nDroid has stopped".
Fixed. I have done three "Clear Data" and restart app (and reload data) cycles. It's all good. I'm liking the Day 1, Day 2, etc progress messages. Thank you.
Great - thanks for the confirmation.