How to debug android c programs by gdbserver on G1

by David Turner » Tue, 24 Feb 2009 16:57:55 GMT


Sponsored Links
 You can use "adb forward tcp:1234 tcp:1234" to forward the local port on
your development machine to the local port 1234 on the device/emulator.
After that, you can do "target remote localhost:1234" in gdb to connect to
your target through gdbserver.





--~--~---------~--~----~------------~-------~--~----~

-~----------~----~----~----~------~----~------~--~---



Other Threads

1. Simple Audio MediaController for Audio

Hi guys,

I've been unable to successfully hookup a MediaController to an audio
MediaPlayer. I've successfully created a MediaPlayer to play audio.
And i've also programatically instantiated a MediaController.

MediaPlayer mp =  myclass.getMediaPlayer(); //My custom class that
returns the current media player

MediaController mc = new MediaController(this);
mc.setAnchorView(button);
mc.setEnabled(true);
mc.show(2000); //does not crash if i comment this out

I have 2 big problems:

1. The above code crashes unless I comment out the show. In which case
the controller does not appear.

I have debugged mp and mc and the button are all not null values, but
I still get the following in logcat:

 java.lang.RuntimeException: Unable to start activity
ComponentInfo{com.test.android.test.activity.testActivity}:
java.lang.NullPointerException
    at
android.app.ActivityThread.performLaunchActivity(ActivityThread.java:
2496)
  at
android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:
2512)
    at android.app.ActivityThread.access$2200(ActivityThread.java:119)
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:
1863)
    at android.os.Handler.dispatchMessage(Handler.java:99)
     at android.os.Looper.loop(Looper.java:123)
    at android.app.ActivityThread.main(ActivityThread.java:4363)
   at java.lang.reflect.Method.invokeNative(Native Method)
   at java.lang.reflect.Method.invoke(Method.java:521)
    at com.android.internal.os.ZygoteInit
$MethodAndArgsCaller.run(ZygoteInit.java:860)
     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
    at dalvik.system.NativeStart.main(Native Method)
 Caused by: java.lang.NullPointerException
    at
android.widget.MediaController.disableUnsupportedButtons(MediaController.java:
258)
    at android.widget.MediaController.show(MediaController.java:288)
   at
com.test.android.test.activity.testActivity.onCreate(testActivity.java:
105)
    at
android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:
1047)
    at
android.app.ActivityThread.performLaunchActivity(ActivityThread.java:
2459)
     ... 11 more

2. The other problem is that I cannot see a way to hookup the
MediaController to Mediaplayer as setMediaPlayer does not take
MediaPlayer as the paramater.

A simple example of a MediaController working with mp3's would be all
that I need!

Thanks alot for your time.

-- 

2. Eclair Release 2

Sebelom berpisah dengan Magic , saya coba upgrade eclair 2.1

tutorial nya bisa liat di sini :

http://planetmax.co.in/viewtopic.php?f=109&t=232&start=0

Eclair [Android 2.1] MADE BY ME [24
Feb]<http://planetmax.co.in/viewtopic.php?f=109&t=232&start=0#p684>


<http://planetmax.co.in/viewtopic.php?p=684&sid=a54abdb587edc5665f9485756249da67#p684>
This Is My Custom Rom
Used Many Roms to build this One

WELCOME TO ECLAIR RELEASE 2

Even B4 HTC GIves Out We Have ANDROID 2.1 Running with MAX Things working


"THIS IS WORKING ONLY N ONLY ON HTC MAGIC 32A NEW RADIO"
Click Here To Update Ur
Radio<http://forum.xda-developers.com/showthread.php?t=605239>

Device I Hav Used For Get This Booting
1. H-Boot - 1.76.2007 (SAPP10000)
2. Radio - 6.35.10.18
3. Recovery -CursorDroids Custom
Recovery<http://www.theandroidkitchen.com/fileshare/Sapphire-32A-Updates/?download=recovery-RA-Magic32A-6.35-v1.5.2.img>

For all this i would thank some people
1. Sanpei -> Awesome Kernel Work 'BRO' I Hope U Get .32 Working Soon
2. People whose all work is used in my rom.
3. People Who gave me inspiration for building it
4. U R Love -> its making me work with out magic as well

32B users i hav not worked on it -> G1 n MT3g
32A users Old Radio -> as its released for G1 u All will get It as well

As u can see HTC itself is providing new updates with new radio n spl (i
think if u do that u can't root)
Shift)
U can roll back as well anytime.


HOW TO GET ROM WITH MAX PERFORMANCE:
3d gallery : paste all pictures in diff folders -> in root of sd-card
Home Screen : use launcher 1 instead of 2
If u find any crashes : some prob in uid
-> go to recovery > others > Fix APK uid mismatches. (most time it happens
so this might solve it) if not report

B4 Playing any games -> end task all apps

While Using from 3d gallery dont -> shift orientation -> potrait to lanscape
or lanscape to portrait

For Version 2
Now Rom Change Log / Details:
Code: Select all <http://planetmax.co.in/viewtopic.php?f=109&t=232&start=0#>1.
Bluetooth Fixed
2. Orientation Fixed
3. Sleep Error is removed
-> if u face it still go to recovery -> and fix uid packages
4. 3D gallery Go fuzzy when u Change Orientation ( Recommended start in the
orientation n stay with that OR use Old gallery)
5. Picasa Sync Wokring
6. Facebook sync (i forgot -> no wipe update coming)
7. I dont rem.(as i do i will write it here) try it.if found bugs Let me
Know


What Might Come in Next Release:
Code: Select all <http://planetmax.co.in/viewtopic.php?f=109&t=232&start=0#>1.
Multi-Touch Map 4.0
2. 3d gallery Fixed
3. some led fixes to come (found it while posting :P )

   - Reply with
quote<http://planetmax.co.in/posting.php?mode=quote&f=109&p=684&sid=a54abdb587edc5665f9485756249da67>

Eclair [Android 2.1] MADE BY ME [24
Feb]<http://planetmax.co.in/viewtopic.php?f=109&t=232&start=0#p684>

[image: 
Post]<http://planetmax.co.in/viewtopic.php?p=684&sid=a54abdb587edc5665f9485756249da67#p684>by
*ahmgsk<http://planetmax.co.in/memberlist.php?mode=viewprofile&u=102&sid=a54abdb587edc5665f9485756249da67>
*  Sat Feb 20, 2010 1:31 am
This Is My Custom Rom
Used Many Roms to build this One

WELCOME TO ECLAIR RELEASE 2

Even B4 HTC GIves Out We Have ANDROID 2.1 Running with MAX Things working


"THIS IS WORKING ONLY N ONLY ON HTC MAGIC 32A NEW RADIO"
Click Here To Update Ur
Radio<http://forum.xda-developers.com/showthread.php?t=605239>

Device I Hav Used For Get This Booting
1. H-Boot - 1.76.2007 (SAPP10000)
2. Radio - 6.35.10.18
3. Recovery -CursorDroids Custom
Recovery<http://www.theandroidkitchen.com/fileshare/Sapphire-32A-Updates/?download=recovery-RA-Magic32A-6.35-v1.5.2.img>

For all this i would thank some people
1. Sanpei -> Awesome Kernel Work 'BRO' I Hope U Get .32 Working Soon
2. People whose all work is used in my rom.
3. People Who gave me inspiration for building it
4. U R Love -> its making me work with out magic as well

32B users i hav not worked on it -> G1 n MT3g
32A users Old Radio -> as its released for G1 u All will get It as well

As u can see HTC itself is providing new updates with new radio n spl (i
think if u do that u can't root)
Shift)
U can roll back as well anytime.


HOW TO GET ROM WITH MAX PERFORMANCE:
3d gallery : paste all pictures in diff folders -> in root of sd-card
Home Screen : use launcher 1 instead of 2
If u find any crashes : some prob in uid
-> go to recovery > others > Fix APK uid mismatches. (most time it happens
so this might solve it) if not report

B4 Playing any games -> end task all apps

While Using from 3d gallery dont -> shift orientation -> potrait to lanscape
or lanscape to portrait

For Version 2
Now Rom Change Log / Details:
Code: Select all <http://planetmax.co.in/viewtopic.php?f=109&t=232&start=0#>1.
Bluetooth Fixed
2. Orientation Fixed
3. Sleep Error is removed
-> if u face it still go to recovery -> and fix uid packages
4. 3D gallery Go fuzzy when u Change Orientation ( Recommended start in the
orientation n stay with that OR use Old gallery)
5. Picasa Sync Wokring
6. Facebook sync (i forgot -> no wipe update coming)
7. I dont rem.(as i do i will write it here) try it.if found bugs Let me
Know


What Might Come in Next Release:
Code: Select all <http://planetmax.co.in/viewtopic.php?f=109&t=232&start=0#>1.
Multi-Touch Map 4.0
2. 3d gallery Fixed
3. some led fixes to come (found it while posting :P )

Check out Version 2



Download:

Click here To Download V2 <http://www.megaupload.com/?d=XLPATHS6>

-- 
www.FeedBerry.com
Gadget Articles Resources

-- 
"Indonesian Android Community [id-android]" 

3. LOVERS SPECIAL

4. Third-party native code protectio

5. SSLiteDatabase.openDatabase()

6. Minta tolong pemakai hero perawan

7. This is wow!