pegasus-frontend icon indicating copy to clipboard operation
pegasus-frontend copied to clipboard

Android logging?

Open nicjansma opened this issue 2 years ago • 2 comments

The issue

I'm unable to find where any debug file or logcat logging happens on Android.

This ticket template mentions it should be in <storage>/pegasus-frontend/lastrun.log, but I don't see the log file there (just my game_dirs.txt and themes/ that load OK). Pegasus has Accessible Android directories... permission to that folder.

I don't see any logging happening to logcat either, though a cursory review of the sourcecode mentions Android logcat. Should it be going there?

(Why I care: I'm trying to understand why loading gamelist and media on my RG405M takes 30+ seconds while the RP3+ only takes ~10 seconds. These two devices have the same chipset and exact same files on the SD card. I was hoping the pegasus log would give some insight).

System info

Retroid Pocket 3+ Anbernic RG405M

Pegasus version

alpha16-67-g40b9b63a (2023-10-23)

Pegasus log

(I was unable to find this log)

nicjansma avatar Nov 08 '23 03:11 nicjansma

On newer Androids, Pegasus can still read files under <storage>/pegasus-frontend/, but might only be able to save the log file at a writable location that Android provides for the apps. I think this should be either at <storage>/Android/data/org.pegasus_frontend.android/, or under /data/user/0/org.pegasus_frontend.android/ somewhere. (The logcat output is only used for debug builds.)

mmatyas avatar Nov 09 '23 09:11 mmatyas

Thanks! Found it at <storage>/Android/data/org.pegasus_frontend.android/files/pegasus-frontend/lastrun.log.

I would suggest a minor update to the Issue template to list that as an alternative location for Android.

(and I've confirmed debug Android builds go to logcat, which is useful. Thanks!)

nicjansma avatar Nov 09 '23 13:11 nicjansma