• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Help Galaxy S2 Bluetooth Logcat Problem.

Hi,

I am running the recently released stock ROM version 4.1.2 downloaded via Kies.

I am trying to debug a Bluetooth problem. However, I cannot see Bluetooth messages when I run the following script using command 'sh btlog' on my android from a terminal:

#!/system/bin/sh
su
print START
# logcat -c
# logcat -v time |grep ".*[bB]luetooth.*"
logcat -v time | grep Bluetooth
print END

It will only output:
START

And, if I run 'logcat | grep Bluetooth' from a terminal session on the android I do not get any output.

But if I run 'sh btlog' from an adb shell I do see the Bluetooth messages, and if I run 'logcat | grep Bluetooth' from an adb shell I also get the expected output.

Can anyone help?
 
Well, I fixed the code problem. Basically, I am executing this script as a task when bluetooth starts. I have to make sure the task manager is executing this as super user. Not in the script itself, but calling from super. Now my logger works, now to debug the exceptions.
 
Back
Top Bottom