[android-developers] Re: Android reset in dalvik layer(system_server or zygote process crash)

2012-03-27 Thread xhy
Hi all,

Please help me, thanks !!!

2012/3/23 xhy xhyg...@gmail.com:
 Hi all,

 The  system reset  many times recently which  in the dalvic layer. I
 get that the watchdog of framework layer  kills
 ActivityManagerService or  WindowsManagerService from log info. Some
 cases are caused by 3party apps, some are the overloading  in system.
 I try to enlarge the dalvik.vm.heap.size from 32MB to 48MB or increase
 the timeout(ANR, IDLE,Service,App freeze etc), but not any valuable.
 Now I have no ideas about this issue, Please help me.Many thanks!!!


 Hardware Info: 1433MHz ,2GB ROM+512MB RAM, 400*800

 Log Info:
 Log 1:
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 184
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 185
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 186
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 187
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 188
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 190
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 191
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 199
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 200
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 201
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 202
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 203
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 209
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 210
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 221
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 223
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 224
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 225
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 231
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 232
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 234
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 235
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 236
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 237
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 238
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 239
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 240
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 241
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 242
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 243
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 244
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 245
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 246
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 248
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 249
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 250
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 251
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 252
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 254
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 255
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 259
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 260
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 261
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 263
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack

Re: [android-developers] Re: Android reset in dalvik layer(system_server or zygote process crash)

2012-03-24 Thread xhy
Hi macterry,

Firstly,thanks for your help, But I can not agree with you.

I think the ActivityManagerService killed by WatchDog is rootcause.
The system_server process will crash if ActivityThread occurs fatal
exception. Many Thanks !!!

2012/3/24 mcterry macte...@gmail.com:
 Hello Hongyue,

 When looking through the logcat, look for the FATAL EXCEPTION.  Then, look
 for the first line that has your applications package name...this will be
 the bug that needs to be fixed.

 In your log, I found this error...
 FATAL EXCEPTION: main
 03-06 11:40:38.873 E/AndroidRuntime(15229): java.lang.NullPointerException
 03-06 11:40:38.873 E/AndroidRuntime(15229): at
 android.app.ActivityThread.attach(ActivityThread.java:3618)

 It looks like you have a class called ActivityThread that has a
 NullPointerException on line 3618.

 If you add a breakpoint (double click on he left side of the editor where
 the line numbers are in Eclipse), and then you can hit that breakpoint and
 see which field/variable/etc. is null.

 Typically, you can use a simple if (foo != null) check...other times there
 is something bigger wrong.

 Let me know if you need help debugging your NPE.
 Hope this helps!

 -Matt

 www.sep.com/mcterry


 On Friday, March 23, 2012 2:45:14 AM UTC-4, Hongyue XU wrote:

 Hi all,

 The  system reset  many times recently which  in the dalvic layer. I
 get that the watchdog of framework layer  kills
 ActivityManagerService or  WindowsManagerService from log info. Some
 cases are caused by 3party apps, some are the overloading  in system.
 I try to enlarge the dalvik.vm.heap.size from 32MB to 48MB or increase
 the timeout(ANR, IDLE,Service,App freeze etc), but not any valuable.
 Now I have no ideas about this issue, Please help me.Many thanks!!!


 Hardware Info: 1433MHz ,2GB ROM+512MB RAM, 400*800

 Log Info:
 Log 1:
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 184
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 185
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 186
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 187
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 188
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 190
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 191
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 199
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 200
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 201
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 202
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 203
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 209
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 210
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 221
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 223
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 224
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 225
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 231
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 232
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 234
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 235
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 236
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 237
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 238
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 239
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 240
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 241
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 242
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 243
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 244
 : 13 (Permission denied)
 03-06 11:40:16.442 E/Watchdog_N( 184): Unable to open stack of tid 245
 : 13 (Permission denied)
 03-06 11:40:16.442 

[android-developers] About The Power And Screen In Gingerbread

2012-01-09 Thread xhy
Hi all,

I execute the command  cat /sys/power/state in shell, but the output
 always is mem even though when the screen is on.So why ?
I check the code in power.c, the func set_screen_state(), I add some
log info,and find that the value had been written.
Thanks!!!

-- 
-
Best Regards
Hongyue Xu

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] out of memory when excute the CTS case of Camera

2011-07-30 Thread xhy
Hi all,

The error occurs when excute CTS case
android.hardware.cts.CametaTest#testPreviewPictureSizesCombination,it fail
in the method takePicture() of  the code.But it is normal when take a
photograph. And the parameters are both same.The follow log info:


V/QualcommCameraHardware( 312): initRaw: initializing mRawHeap.
I/QualcommCameraHardware( 312): constructing MemPool snapshot camera backed
by pmem pool /dev/pmem_adsp: 1 frames @ 7589376 bytes, buffer size 7589376
E/QualcommCameraHardware( 312): mName snapshot camera
E/QualcommCameraHardware( 312): pmem_pool /dev/pmem_adsp
E/QualcommCameraHardware( 312): num_buffers 1
E/QualcommCameraHardware( 312): frame_size 7589376
E/QualcommCameraHardware( 312): buffer_size 7589376
E/MemoryHeapBase( 312): mmap(fd=49, size=7589888) failed (Out of memory)
E/QualcommCameraHardware( 312): failed to construct master heap for pmem
pool /dev/pmem_adsp
E/QualcommCameraHardware( 312): initRaw X failed
I/QualcommCameraHardware( 312): ~PmemPool: snapshot camera E
I/QualcommCameraHardware( 312): ~PmemPool: snapshot camera X
V/QualcommCameraHardware( 312): destroying MemPool snapshot camera
V/QualcommCameraHardware( 312): destroying MemPool snapshot camera completed
E/QualcommCameraHardware( 312): initRaw X: error initializing mRawHeap
E/QualcommCameraHardware( 312): initRaw failed. Not taking picture.
V/Camera ( 846): setPreviewCallbackFlags
V/Camera ( 846): disconnect
V/QualcommCameraHardware( 312): stopPreview: E
I/QualcommCameraHardware( 312): stopPreviewInternal E: 0
I/QualcommCameraHardware( 312): stopPreviewInternal X: 0
V/QualcommCameraHardware( 312): stopPreview: X
V/QualcommCameraHardware( 312): cancelPicture: E


-- 
-
Best Regards
Hongyue Xu

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] How to customize a permission for a service in Framework ?

2011-06-07 Thread xhy
Hi all,

I want to customize a permission for a service in Framework. The service is
also customized by me, the implement's mechanism is IPC (aidl) and boots
with the device. And it checks permissions  before apps call the service's
method. But the result of checking permissions is always failure:denied.

I define the permission in framework/base/core/res/Manifest.xml:

permission android:name=com.android.permission.SIMCARD_AUTHENTICATION
 android:protectionLevel=dangerous /


Service code:

private boolean checkPermissions() {
Log.d(TAG,checkPermissions+mContext.checkCallingOrSelfPermission(android.Manifest.permission.SIMCARD_AUTHENTICATION));
Log.d(TAG,Binder.getCallingPid()=+Binder.getCallingPid()+Binder.getCallingUid()=+Binder.getCallingUid());
if
(mContext.checkCallingOrSelfPermission(android.Manifest.permission.SIMCARD_AUTHENTICATION)
!= PackageManager.PERMISSION_GRANTED){
return false;
}
return true;
}
Note: the log info is always -1(denied) and the other is normal.

The manifest.xml of APPs:

application
activity android:name=DefaultActivity android:label=@string/unknown
intent-filter
action android:name=android.intent.action.MAIN /
category android:name=android.intent.category.LAUNCHER /
/intent-filter
/activity
use-permissions android:name
=com.android.permission.SIMCARD_AUTHENTICATION/use-permissions


Who can help me ? Thanks!

-- 
-
Best Regards
Hongyue Xu

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] android.webkit.cts.WebViewTest#testFindNext

2011-01-29 Thread xhy
Hi all, there is a cts case which I can not ran success,and  I can not find
the root cause, Anybody came across the same question? Offer me
some clues,Many thanks!!!

/
cts_host  start --plan CTS -t android.webkit.cts.WebViewTest#testFindNext
cts_host  start test android.webkit.cts.WebViewTest#testFindNext
==
Test package: android.webkit
android.webkit.cts.WebViewTest#testFindNext..(fail)
junit.framework.AssertionFailedError at
android.webkit.cts.WebViewTest.testFindNext(WebViewTest.java:948)
at android.webkit.cts.WebViewTest.testFindNext(WebViewTest.java:948)
at java.lang.reflect.Method.invokeNative(Native Method)
at
android.test.InstrumentationTestCase.runMethod(InstrumentationTestCase.java:236)
at
android.test.InstrumentationTestCase.runTest(InstrumentationTestCase.java:226)
at
android.test.ActivityInstrumentationTestCase2.runTest(ActivityInstrumentationTestCase2.java:206)
at android.test.AndroidTestRunner.runTest(AndroidTestRunner.java:200)
at android.test.AndroidTestRunner.runTest(AndroidTestRunner.java:185)
at
android.test.InstrumentationTestRunner.onStart(InstrumentationTestRunner.java:461)
at
android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1488)
at android.webkit.cts.WebViewTest.testFindNext(WebViewTest.java:948)
at java.lang.reflect.Method.invokeNative(Native Method)
at
android.test.InstrumentationTestCase.runMethod(InstrumentationTestCase.java:236)
at
android.test.InstrumentationTestCase.runTest(InstrumentationTestCase.java:226)
at
android.test.ActivityInstrumentationTestCase2.runTest(ActivityInstrumentationTestCase2.java:206)
at android.test.AndroidTestRunner.runTest(AndroidTestRunner.java:200)
at android.test.AndroidTestRunner.runTest(AndroidTestRunner.java:185)
at
android.test.InstrumentationTestRunner.onStart(InstrumentationTestRunner.java:461)
at
android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1488)

==
Time: 1502708.541s


BR
Hongyue Xu

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: android.webkit.cts.WebViewTest#testFindNext

2011-01-29 Thread xhy
And I also find that the  Find all instances of a word on the page and
highlight them appears in the top and bottom of the screen at the same
time,But the normal just appear one in the screen and the other one will
appear when excute the scrol func. Why?

2011/1/29 xhy xhyg...@gmail.com

 Hi all, there is a cts case which I can not ran success,and  I can not find
 the root cause, Anybody came across the same question? Offer me
 some clues,Many thanks!!!


 /
 cts_host  start --plan CTS -t android.webkit.cts.WebViewTest#testFindNext
 cts_host  start test android.webkit.cts.WebViewTest#testFindNext
 ==
 Test package: android.webkit
 android.webkit.cts.WebViewTest#testFindNext..(fail)
 junit.framework.AssertionFailedError at
 android.webkit.cts.WebViewTest.testFindNext(WebViewTest.java:948)
 at android.webkit.cts.WebViewTest.testFindNext(WebViewTest.java:948)
 at java.lang.reflect.Method.invokeNative(Native Method)
 at
 android.test.InstrumentationTestCase.runMethod(InstrumentationTestCase.java:236)
 at
 android.test.InstrumentationTestCase.runTest(InstrumentationTestCase.java:226)
 at
 android.test.ActivityInstrumentationTestCase2.runTest(ActivityInstrumentationTestCase2.java:206)
 at android.test.AndroidTestRunner.runTest(AndroidTestRunner.java:200)
 at android.test.AndroidTestRunner.runTest(AndroidTestRunner.java:185)
 at
 android.test.InstrumentationTestRunner.onStart(InstrumentationTestRunner.java:461)
 at
 android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1488)
 at android.webkit.cts.WebViewTest.testFindNext(WebViewTest.java:948)
 at java.lang.reflect.Method.invokeNative(Native Method)
 at
 android.test.InstrumentationTestCase.runMethod(InstrumentationTestCase.java:236)
 at
 android.test.InstrumentationTestCase.runTest(InstrumentationTestCase.java:226)
 at
 android.test.ActivityInstrumentationTestCase2.runTest(ActivityInstrumentationTestCase2.java:206)
 at android.test.AndroidTestRunner.runTest(AndroidTestRunner.java:200)
 at android.test.AndroidTestRunner.runTest(AndroidTestRunner.java:185)
 at
 android.test.InstrumentationTestRunner.onStart(InstrumentationTestRunner.java:461)
 at
 android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1488)

 ==
 Time: 1502708.541s

 
 BR
 Hongyue Xu




-- 
Hongyue Xu

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: can not visit the sdcard when add the android.uid.system

2010-11-05 Thread xhy
Thank you sir,I want to visit the file which is under  the /system/lib,But
at the same time,I also want to read the USB device.So what can i do ?

2010/11/5 Chris Stratton cs07...@gmail.com

 If the sdcard gets unmounted, any process with an open file handle to
 it gets killed.

 Letting the system process be killed was considered a bad thing.  To
 avoid that, the system process (which is to say any system process) is
 not allowed to access the SD card.

 FYI, you probably will not be able to install your apk with the system
 uid on most secured devices, unless you are in possession of the
 system certificate for the devices on which you want to deploy.

 What exactly do you need to access in the /system folder?  You do know
 it's mounted read-only, right?

 Technically, anything regarding the system folder is beyond the bounds
 of discussion of android-developers which is supposed to be confined
 to the SDK APIs.

 On Nov 4, 10:57 pm, xhy xhyg...@gmail.com wrote:
  Hi all,Now I come across a question,I want to visit the system folder in
 the
  android file system.So i add the
 android:SharedUserId=android.uid.system
  in the manifest.xml,But I can not visit the USB device if that.
 
  --
  Hongyue Xu

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
Hongyue Xu

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] can not visit the sdcard when add the android.uid.system

2010-11-04 Thread xhy
Hi all,Now I come across a question,I want to visit the system folder in the
android file system.So i add the android:SharedUserId=android.uid.system
in the manifest.xml,But I can not visit the USB device if that.

-- 
Hongyue Xu

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] MediaPlayer.OnCompletionListener can't get the state while playing mp3(44.1 or 48 KHZ) fastforwardly to it's end ?

2010-07-22 Thread xhy
Hi all,I fastwordly  play the mp3 through MediaPlayer's function
seekTo(int),But the MediaPlayer.OnCompletionListener can't get the state
that if  the process of mp3 is end. It will stop when it fastword the file's
end sometime. The mp3 is 44.1KHZ or 48KHZ,but some 44.1KHZ mp3 files do not
exist such problem.why?Is  MediaPlayer's function seekTo(int)?
-- 
xhy

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] how to control requery's time of Cursor ?

2010-07-22 Thread xhy
I want to display some thing in the LiveFolder dynamicly.So i implent the
abscusor.But how to control  requery's time of Cursor ?

-- 
xhy

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] LiveFolder ?

2010-07-08 Thread xhy
hi all,
Recently,i developed a intrest in the livefolder,But how to start a activity
from the livefolder ? No startActivity() int the source code which i am
reading,but it can start other activity
.So why? Thanks.
-- 
xhy

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] how to see the the usage of memory in the android?

2010-06-30 Thread xhy
1 I want to see the usage of memory in the android through the procrank
command,but throw a error error: creating kernel interface. Why/
2 if use the top command, but the info of the %MEM is not correct. Because
all the pid's info's sum will 100% ,so Why?


-- 
xhy

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: how to play a 8192*8192 image ?

2010-06-28 Thread xhy
Thank you ! I will have a try!

2010/6/28 Streets Of Boston flyingdutc...@gmail.com

 Then you need to tell them it is impossible. Ask them what the maximum
 resolution is of the output they desire. And i'm curious which output-
 device your clients have in mind if it needs a 8192x8192 resolution.

 Anyway, if it is an HDTV, more than 1920x1080 is not necessary. And if
 you hook up the phone to an output-device using HDMI, more than 1080p
 is not supported...

 If it is an Android phone, more than 854x480 is not necessary.

 They still can supply you with a 8192x8192 image, but for display you
 need to scale it down to the display resolution
 (BitmapFactory.Options.inSampleSize having a value greater than 1).

 On Jun 27, 8:02 pm, xhy xhyg...@gmail.com wrote:
  In fact  the clients demand it,so i have no idea.
 
  2010/6/28 Kostya Vasilyev kmans...@gmail.com
 
 
 
 
 
   27.06.2010 21:25, Streets Of Boston пишет:
 
Wow, do you have a big screen TV capable of displaying 8192*8192 pixel
   images!?
   I doubt it:-)
 
   If you have an HDTV of 1080p, then the max resolution is 1920*1080
   (about 2MPixels). There's no need to go larger.
 
   Besides, the phone's real output resolution might be even smaller (to
 match
   the screen).
 
   --
   Kostya Vasilev -- WiFi Manager + pretty widget --
  http://kmansoft.wordpress.com
 
   --
   You received this message because you are subscribed to the Google
   Groups Android Developers group.
   To post to this group, send email to
 android-developers@googlegroups.com
   To unsubscribe from this group, send email to
   android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 android-developers%2bunsubs-cr...@googlegroups.comandroid-developers%252bunsubs-cr...@googlegroups.com
 
   For more options, visit this group at
  http://groups.google.com/group/android-developers?hl=en
 
  --
  xhy- Hide quoted text -
 
  - Show quoted text -

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
xhy

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: how to play a 8192*8192 image ?

2010-06-27 Thread xhy
i want to  paly a 8192*8192 image int a big TV screen,as a result  such a
big image is needed.

2010/6/25 Mike dg vinb...@gmail.com

 I doubt you have an 8192x8192 screen. So figure out what you re
 actually doing with the image and then only use as much as you need or
 all of it scaled to screen size.

 On Jun 25, 6:52 am, Mark Murphy mmur...@commonsware.com wrote:
  On Fri, Jun 25, 2010 at 6:42 AM, xhy xhyg...@gmail.com wrote:
   I want to play a   8192*8192 image,but the system exists a overflow of
   memory exception,what should i do ? Thank you!
 
  That is a ~200MB image uncompressed (8192 x 8192 x 3 bytes), and you
  have 16MB to work with.
 
  The simplest option is to use a smaller image to start with.
 
  The next-simplest option is to scale the image, as youken suggests,
  though this will take some time.
 
  The option that keeps your size is to split the image into tiles, like
  Google Maps does, and show only a few tiles at a time.
 
  --
  Mark Murphy (a Commons Guy)http://commonsware.com|
 http://github.com/commonsguyhttp://commonsware.com/blog|http://twitter.com/commonsguyhttp://github.com/commonsguyhttp://commonsware.com/blog%7Chttp://twitter.com/commonsguy
 
  _The Busy Coder's Guide to *Advanced* Android Development_ Version 1.6
  Available!

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
xhy

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: how to play a 8192*8192 image ?

2010-06-27 Thread xhy
In fact  the clients demand it,so i have no idea.

2010/6/28 Kostya Vasilyev kmans...@gmail.com

 27.06.2010 21:25, Streets Of Boston пишет:

  Wow, do you have a big screen TV capable of displaying 8192*8192 pixel
 images!?
 I doubt it:-)

 If you have an HDTV of 1080p, then the max resolution is 1920*1080
 (about 2MPixels). There's no need to go larger.


 Besides, the phone's real output resolution might be even smaller (to match
 the screen).

 --
 Kostya Vasilev -- WiFi Manager + pretty widget --
 http://kmansoft.wordpress.com


 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
xhy

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] how to play a 8192*8192 image ?

2010-06-25 Thread xhy
Hi,all
I want to play a   8192*8192 image,but the system exists a overflow of
memory exception,what should i do ? Thank you!
-- 
xhy

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] The difference between removeViewInLayout() and removeAllViews()

2010-05-23 Thread xhy
hi all ,i inflate a xml ,and add it to a mapview .But i want to remove it
when  i click a button.I must click the button two times sothat i can remove
it when i  use the  removeViewInLayout()  method ,but if
using removeAllViews() will do . Why?Thank you !


the code is:
add the view to mapview:

 ll = (LinearLayout)mInflater.inflate(R.layout.bubble,null
);
 LayoutParams lp = new
LayoutParams(ViewGroup.LayoutParams.WRAP_CONTENT,
ViewGroup.LayoutParams.WRAP_CONTENT, p, 0, -70,
 LayoutParams.MODE_MAP | LayoutParams.CENTER);

 map.addView(ll,lp);


remove it:
map.removeAllViews(); ok
map.removeViewInLayout(ll); ///must click two times

-- 
xhy

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] how to transfer a geopoint from a mapActiviy to the other activity

2010-05-21 Thread xhy
hi all,i want to  transfer a geopoint from a mapActiviy to the other
activity,the code is below:

  Geopoint p= items.get(i).getPoint();
   Intent intent=new Intent();
Bundle bundle=new Bundle();
bundle.putSerializable(key, (Serializable)p);
intent.putExtras(bundle);
intent.setClass(TaoMapMain.this, ShopActivity.class);
   startActivity(intent);

But the the system  exists a error java.lang.ClasscastException,who can
offer me a best methods? if i transfer  latitude and logtitude,then it is a
fool way! any best method?
-- 
xhy

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] how to transfer a geopoint from a mapActiviy to the other activity

2010-05-21 Thread xhy
i just think that tranfering  a Object  is a senseable  way !

2010/5/21 TreKing treking...@gmail.com

 On Fri, May 21, 2010 at 1:32 AM, xhy xhyg...@gmail.com wrote:

 But the the system  exists a error java.lang.ClasscastException


 What do you expect when trying to cast an object to a type it does not
 derive from (GeoPoint to Serializable)?


 ,who can offer me a best methods?


 GeoPoint has two things you care about: latitude and longitude - pass that.


 if i transfer  latitude and logtitude,then it is a fool way! any best
 method?


 This sentence makes no sense to me.


 -
 TreKing - Chicago transit tracking app for Android-powered devices
 http://sites.google.com/site/rezmobileapps/treking

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
xhy

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] how to add a dialog or a window in the map when click the marker ?

2010-05-21 Thread xhy
Can you give me a sample ? Thank you !

2010/5/22 TreKing treking...@gmail.com

 On Fri, May 21, 2010 at 7:54 AM, xhy xhyg...@gmail.com wrote:

 hi all,i want to add a  dialog or a window  in the map when click the
 marker  as folows?but  i don't know what to do. Does put the  dialog int the
 Overlay or MapView ? Thanks!


 Create a layout that looks like that balloon then add it to the mapview
 with the appropriate layout. That's it.



 -
 TreKing - Chicago transit tracking app for Android-powered devices
 http://sites.google.com/site/rezmobileapps/treking

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
xhy

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] how to transfer a geopoint from a mapActiviy to the other activity

2010-05-21 Thread xhy
oh,I see ! Thank you!

2010/5/22 TreKing treking...@gmail.com

 On Fri, May 21, 2010 at 10:11 AM, xhy xhyg...@gmail.com wrote:

 i just think that tranfering  a Object  is a senseable  way !


 It is!
 But GeoPoint is neither Serializable or Parcelable!
 So you can't!
 If you want to transfer an object, create your own object that has lat and
 lon properties and is Serializable or Parcelable and pass that!


 -
 TreKing - Chicago transit tracking app for Android-powered devices
 http://sites.google.com/site/rezmobileapps/treking

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
xhy

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] how to add a dialog or a window in the map when click the marker ?

2010-05-21 Thread xhy
Thank you ! I wiil have a try right now.

2010/5/22 TreKing treking...@gmail.com

 On Fri, May 21, 2010 at 8:28 PM, xhy xhyg...@gmail.com wrote:

 Can you give me a sample ? Thank you !


 I *could*, but I don't feel like it :P

 Really though, this is pretty straightforward:
 Step 1: create the layout you want to show as your popup.
 Step 2: when you want to show said popup (like on tapping an overlay),
 inflate it and use MapView.addChild() with the appropriate LayoutParameters
 to position it where you want.

 To get going you can even skip step one and just use a TextView with a
 simple message. Try it.



 -
 TreKing - Chicago transit tracking app for Android-powered devices
 http://sites.google.com/site/rezmobileapps/treking

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
xhy

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en