Switching layout from button clicks.

Put problem concerning Views, Layouts and other XML-Resources (like AndroidManifest) here.

Switching layout from button clicks.

Postby KanedaSyndrome » Wed Nov 12, 2008 2:16 pm

Hi I have a problem that I hope you can help me with, I will post my code:

Code: Select all
package anritsu.futuretechnologies.connectivity;

import android.app.Activity;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;

public class Connectivity extends Activity {
    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle icicle) {
        super.onCreate(icicle);
        setContentView(R.layout.main);
   
        Button backbutton1 = (Button)findViewById(R.id.button_back1);
        Button button1 = (Button)findViewById(R.id.button1);
       
        button1.setOnClickListener(new OnClickListener()
        {
            public void onClick(View viewParam)
            {
               setContentView(R.layout.menupoint1);
            }
       
        });
       
       
        backbutton1.setOnClickListener(new OnClickListener()
        {
            public void onClick(View viewParam)
            {
               setContentView(R.layout.main);
            }
        });
       
                     
    }
}



Now the problem is that I get no errors, but when I try to run it I get an error in the emulator that the activity closed unexpectedly.

This only happens when I try to have two buttons working from the buttonname.setOnClickListener

If I remove one of them and just have one button used it works fine... I don't see what's wrong since I get no errors. Is it because it's under the same oncreate or something? You have it the same way in yours, but perhaps it's because they load a new xml layout file each when they are pushed?

I have main.xml and a menupoint1.xml, the idea is that pressing a button in the main.xml will take the user to the menupoint1.xml layout, and with a back button in menupoint1.xml it should take the user back to main.xml, basically I am just trying to get my head around getting buttons to work.

Or perhaps the error is in the (View viewParam), I am not that sharp with java yet and this might refer to a parameter in the main.xml and when the listener tries to listen on a button that's in a different layout file it messes up?

Anyway, if you could like really cut it out in paper for me, I would be very appreciative.
KanedaSyndrome
Developer
Developer
 
Posts: 41
Joined: Tue Nov 11, 2008 3:32 pm

Top

Postby MrSnowflake » Wed Nov 12, 2008 2:25 pm

Check this and then post the relevant part of the log.
User avatar
MrSnowflake
Moderator
Moderator
 
Posts: 1439
Joined: Sat Feb 16, 2008 3:11 pm
Location: Flanders, Belgium

Postby KanedaSyndrome » Wed Nov 12, 2008 2:36 pm

Am a bit new at this, so please excuse me if I am not sure which is the relevant bit of the log, just posting it all in verbose and in error mode:

Verbose
Code: Select all
11-12 14:26:39.736: ERROR/mountd(19): could not read initial mass storage state
11-12 14:26:39.746: INFO/DEBUG(20): debuggerd: Sep 22 2008 13:36:12
11-12 14:26:40.027: ERROR/flash_image(28): can't find recovery partition
11-12 14:26:40.666: DEBUG/AndroidRuntime(23): >>>>>>>>>>>>>> AndroidRuntime START <<<<<<<<<<<<<<
11-12 14:26:40.666: DEBUG/AndroidRuntime(23): CheckJNI is ON
11-12 14:26:40.846: DEBUG/RILD(22): overriding with -s /dev/socket/qemud_gsm
11-12 14:26:41.116: DEBUG/AndroidRuntime(23): --- registering native functions ---
11-12 14:26:41.247: INFO/(24): ServiceManager: 0xaab8
11-12 14:26:41.277: INFO/AudioFlinger(24): AudioFlinger's main thread ready to run.
11-12 14:26:41.296: INFO/CameraService(24): CameraService started: pid=24
11-12 14:26:41.876: INFO/Zygote(23): Preloading classes...
11-12 14:26:41.885: DEBUG/dalvikvm(23): GC freed 746 objects / 41232 bytes in 10ms
11-12 14:26:41.997: DEBUG/dalvikvm(23): GC freed 302 objects / 18576 bytes in 5ms
11-12 14:26:42.077: DEBUG/dalvikvm(23): GC freed 313 objects / 18952 bytes in 6ms
11-12 14:26:42.177: DEBUG/dalvikvm(23): Trying to load lib /system/lib/libmedia_jni.so 0x0
11-12 14:26:42.305: DEBUG/dalvikvm(23): Added shared lib /system/lib/libmedia_jni.so 0x0
11-12 14:26:42.305: DEBUG/dalvikvm(23): Trying to load lib /system/lib/libmedia_jni.so 0x0
11-12 14:26:42.305: DEBUG/dalvikvm(23): Shared lib '/system/lib/libmedia_jni.so' already loaded in same CL 0x0
11-12 14:26:42.305: DEBUG/dalvikvm(23): Trying to load lib /system/lib/libmedia_jni.so 0x0
11-12 14:26:42.305: DEBUG/dalvikvm(23): Shared lib '/system/lib/libmedia_jni.so' already loaded in same CL 0x0
11-12 14:26:42.986: DEBUG/dalvikvm(23): GC freed 3716 objects / 180824 bytes in 21ms
11-12 14:26:43.086: DEBUG/dalvikvm(23): GC freed 262 objects / 18552 bytes in 15ms
11-12 14:26:43.176: DEBUG/dalvikvm(23): GC freed 403 objects / 23712 bytes in 17ms
11-12 14:26:43.306: DEBUG/dalvikvm(23): GC freed 137 objects / 26648 bytes in 19ms
11-12 14:26:43.537: DEBUG/dalvikvm(23): GC freed 740 objects / 46528 bytes in 33ms
11-12 14:26:43.675: DEBUG/dalvikvm(23): GC freed 385 objects / 23872 bytes in 32ms
11-12 14:26:43.746: DEBUG/dalvikvm(23): Trying to load lib /system/lib/libwebcore.so 0x0
11-12 14:26:43.787: DEBUG/dalvikvm(23): Added shared lib /system/lib/libwebcore.so 0x0
11-12 14:26:43.987: DEBUG/dalvikvm(23): GC freed 490 objects / 28224 bytes in 33ms
11-12 14:26:44.116: DEBUG/dalvikvm(23): GC freed 298 objects / 21016 bytes in 33ms
11-12 14:26:44.225: DEBUG/dalvikvm(23): GC freed 388 objects / 21032 bytes in 35ms
11-12 14:26:44.457: DEBUG/dalvikvm(23): GC freed 1472 objects / 76720 bytes in 36ms
11-12 14:26:44.646: DEBUG/dalvikvm(23): GC freed 611 objects / 45056 bytes in 35ms
11-12 14:26:45.906: DEBUG/dalvikvm(23): GC freed 14754 objects / 517344 bytes in 60ms
11-12 14:26:46.315: DEBUG/dalvikvm(23): GC freed 11451 objects / 484136 bytes in 59ms
11-12 14:26:46.445: DEBUG/SSLSocketFactory(23): Using factory org.apache.harmony.xnet.provider.jsse.OpenSSLSocketFactoryImpl@4011c688
11-12 14:26:46.496: DEBUG/dalvikvm(23): GC freed 4085 objects / 172440 bytes in 49ms
11-12 14:26:46.707: DEBUG/dalvikvm(23): GC freed 640 objects / 34200 bytes in 45ms
11-12 14:26:46.816: DEBUG/dalvikvm(23): GC freed 570 objects / 29848 bytes in 45ms
11-12 14:26:46.926: DEBUG/dalvikvm(23): GC freed 368 objects / 26208 bytes in 47ms
11-12 14:26:46.935: INFO/Zygote(23): ...preloaded 854 classes in 5061ms.
11-12 14:26:46.986: DEBUG/dalvikvm(23): GC freed 43 objects / 2424 bytes in 46ms
11-12 14:26:46.986: INFO/Zygote(23): Preloading resources...
11-12 14:26:47.047: DEBUG/dalvikvm(23): GC freed 6 objects / 8928 bytes in 52ms
11-12 14:26:47.417: DEBUG/dalvikvm(23): GC freed 180 objects / 9376 bytes in 48ms
11-12 14:26:47.496: DEBUG/dalvikvm(23): GC freed 123 objects / 4856 bytes in 54ms
11-12 14:26:47.726: INFO/Zygote(23): ...preloaded 42 resources in 741ms.
11-12 14:26:47.775: DEBUG/dalvikvm(23): GC freed 115 objects / 5520 bytes in 48ms
11-12 14:26:47.826: DEBUG/dalvikvm(23): GC freed 181 objects / 7400 bytes in 49ms
11-12 14:26:47.877: DEBUG/dalvikvm(23): GC freed 2 objects / 48 bytes in 48ms
11-12 14:26:47.887: INFO/dalvikvm(23): Splitting out new zygote heap
11-12 14:26:47.896: INFO/dalvikvm(23): System server process 49 has been created
11-12 14:26:47.896: INFO/Zygote(23): Accepting command socket connections
11-12 14:26:47.976: DEBUG/dalvikvm(49): Trying to load lib /system/lib/libandroid_servers.so 0x0
11-12 14:26:48.105: DEBUG/dalvikvm(49): Added shared lib /system/lib/libandroid_servers.so 0x0
11-12 14:26:48.115: INFO/sysproc(49): Entered system_init()
11-12 14:26:48.115: INFO/sysproc(49): ServiceManager: 0xbf788
11-12 14:26:48.115: INFO/SurfaceFlinger(49): SurfaceFlinger is starting
11-12 14:26:48.115: ERROR/MemoryHeapBase(49): error opening /dev/pmem: No such file or directory
11-12 14:26:48.115: INFO/SurfaceFlinger(49): SurfaceFlinger's main thread ready to run. Initializing graphics H/W...
11-12 14:26:48.127: ERROR/SurfaceFlinger(49): Couldn't open /sys/android_power/wait_for_fb_sleep or /sys/android_power/wait_for_fb_wake
11-12 14:26:48.167: ERROR/GLLogger(49): couldn't load <libhgl.so> library (Cannot find library)
11-12 14:26:48.167: INFO/SurfaceFlinger(49): EGL informations:
11-12 14:26:48.167: INFO/SurfaceFlinger(49): # of configs : 4
11-12 14:26:48.167: INFO/SurfaceFlinger(49): vendor    : Google Inc.
11-12 14:26:48.167: INFO/SurfaceFlinger(49): version   : 1.2 Android META-EGL
11-12 14:26:48.167: INFO/SurfaceFlinger(49): extensions: EGL_ANDROID_query_string_config EGL_ANDROID_swap_rectangle
11-12 14:26:48.167: INFO/SurfaceFlinger(49): ext/config: EGL_ANDROID_swap_rectangle
11-12 14:26:48.167: INFO/SurfaceFlinger(49): Client API: OpenGL ES
11-12 14:26:48.167: INFO/EGLDisplaySurface(49): using (fd=21)
11-12 14:26:48.167: INFO/EGLDisplaySurface(49): id           =
11-12 14:26:48.167: INFO/EGLDisplaySurface(49): xres         = 320 px
11-12 14:26:48.167: INFO/EGLDisplaySurface(49): yres         = 480 px
11-12 14:26:48.167: INFO/EGLDisplaySurface(49): xres_virtual = 320 px
11-12 14:26:48.167: INFO/EGLDisplaySurface(49): yres_virtual = 960 px
11-12 14:26:48.167: INFO/EGLDisplaySurface(49): bpp          = 16
11-12 14:26:48.167: INFO/EGLDisplaySurface(49): r            = 11:5
11-12 14:26:48.167: INFO/EGLDisplaySurface(49): g            =  5:6
11-12 14:26:48.167: INFO/EGLDisplaySurface(49): b            =  0:5
11-12 14:26:48.167: INFO/EGLDisplaySurface(49): width        = 49 mm (165.877548 dpi)
11-12 14:26:48.167: INFO/EGLDisplaySurface(49): height       = 73 mm (167.013702 dpi)
11-12 14:26:48.167: INFO/EGLDisplaySurface(49): refresh rate = 60.00 Hz
11-12 14:26:48.177: INFO/SurfaceFlinger(49): OpenGL informations:
11-12 14:26:48.177: INFO/SurfaceFlinger(49): vendor    : Google Inc.
11-12 14:26:48.177: INFO/SurfaceFlinger(49): renderer  : Android PixelFlinger 1.0
11-12 14:26:48.177: INFO/SurfaceFlinger(49): version   : OpenGL ES-CM 1.0
11-12 14:26:48.177: INFO/SurfaceFlinger(49): extensions: GL_OES_byte_coordinates GL_OES_fixed_point GL_OES_single_precision GL_OES_read_format GL_OES_compressed_paletted_texture GL_OES_draw_texture GL_OES_matrix_get GL_OES_query_matrix GL_ARB_texture_compression GL_ARB_texture_non_power_of_two GL_ANDROID_direct_texture GL_ANDROID_user_clip_plane GL_ANDROID_vertex_buffer_object GL_ANDROID_generate_mipmap
11-12 14:26:48.196: INFO/sysproc(49): System server: starting Android runtime.
11-12 14:26:48.196: INFO/sysproc(49): System server: starting Android services.
11-12 14:26:48.196: INFO/SystemServer(49): Entered the Android system server!
11-12 14:26:48.216: INFO/sysproc(49): System server: entering thread pool.
11-12 14:26:48.225: ERROR/GLLogger(49): couldn't load <libhgl.so> library (Cannot find library)
11-12 14:26:48.297: INFO/SystemServer(49): Starting Power Manager.
11-12 14:26:48.387: INFO/SystemServer(49): Starting Activity Manager.
11-12 14:26:48.507: INFO/SystemServer(49): Starting telephony registry
11-12 14:26:48.516: INFO/SystemServer(49): Starting Package Manager.
11-12 14:26:48.536: INFO/Installer(49): connecting...
11-12 14:26:48.536: INFO/installd(27): new connection
11-12 14:26:48.936: DEBUG/PackageManager(49): Scanning app dir /system/framework
11-12 14:26:48.956: WARN/PackageParser(49): Bad element under <manifest>: eat-comment
11-12 14:26:48.966: WARN/PackageParser(49): Bad element under <manifest>: eat-comment
11-12 14:26:48.975: WARN/PackageParser(49): Bad element under <manifest>: eat-comment
11-12 14:26:48.975: WARN/PackageParser(49): Bad element under <manifest>: eat-comment
11-12 14:26:48.985: WARN/PackageParser(49): Bad element under <manifest>: eat-comment
11-12 14:26:48.985: WARN/PackageParser(49): Bad element under <manifest>: eat-comment
11-12 14:26:48.985: WARN/PackageParser(49): Bad element under <manifest>: eat-comment
11-12 14:26:48.997: WARN/PackageParser(49): Bad element under <manifest>: eat-comment
11-12 14:26:48.997: WARN/PackageParser(49): Bad element under <manifest>: eat-comment
11-12 14:26:49.026: WARN/PackageParser(49): Bad element under <manifest>: eat-comment
11-12 14:26:49.026: WARN/PackageParser(49): Bad element under <manifest>: eat-comment
11-12 14:26:49.097: DEBUG/PackageManager(49): Scanning app dir /system/app
11-12 14:26:49.177: INFO/ARMAssembler(49): generated scanline__00000177:03545404_00001A04_00000000 [ 61 ipp] (86 ins) at [0x1c84c8:0x1c8620] in 2761524 ns
11-12 14:26:49.327: DEBUG/dalvikvm(49): GC freed 5878 objects / 249776 bytes in 202ms
11-12 14:26:49.466: INFO/ARMAssembler(49): generated scanline__00000177:03010104_00001A01_00000000 [ 40 ipp] (65 ins) at [0x1c3068:0x1c316c] in 777753 ns
11-12 14:26:49.466: INFO/ARMAssembler(49): generated scanline__00000177:03545404_00000A01_00000000 [ 48 ipp] (72 ins) at [0x1c5618:0x1c5738] in 647568 ns
11-12 14:26:50.377: DEBUG/PackageManager(49): Scanning app dir /data/app
11-12 14:26:50.676: DEBUG/dalvikvm(49): GC freed 3503 objects / 202528 bytes in 95ms
11-12 14:26:50.785: WARN/PackageParser(49): Intent filter for activity ActivityIntentInfo{433f5be0 com.example.android.apis.media.MediaPlayerDemo_Audio} defines no actions
11-12 14:26:50.785: WARN/PackageParser(49): Intent filter for activity ActivityIntentInfo{433b1ba0 com.example.android.apis.media.MediaPlayerDemo_Video} defines no actions
11-12 14:26:50.855: DEBUG/PackageManager(49): Scanning app dir /data/app-private
11-12 14:26:50.865: INFO/PackageManager(49): Time to scan packages: 1.995 seconds
11-12 14:26:51.076: DEBUG/dalvikvm(49): GC freed 2735 objects / 162736 bytes in 85ms
11-12 14:26:51.105: INFO/SystemServer(49): Starting Content Manager.
11-12 14:26:51.267: INFO/SystemServer(49): Starting System Content Providers.
11-12 14:26:51.267: INFO/ActivityThread(49): Publishing provider settings: com.android.providers.settings.SettingsProvider
11-12 14:26:51.297: INFO/ActivityThread(49): Publishing provider android.server.checkin: android.server.checkin.CheckinProvider
11-12 14:26:51.307: INFO/ActivityThread(49): Publishing provider sync: android.content.SyncProvider
11-12 14:26:51.315: INFO/SystemServer(49): Starting Battery Service.
11-12 14:26:51.325: ERROR/BatteryService(49): Could not open '/sys/class/power_supply/usb/online'
11-12 14:26:51.325: ERROR/BatteryService(49): Could not open '/sys/class/power_supply/battery/batt_vol'
11-12 14:26:51.325: ERROR/BatteryService(49): Could not open '/sys/class/power_supply/battery/batt_temp'
11-12 14:26:51.415: INFO/SystemServer(49): Starting Alarm Manager.
11-12 14:26:51.446: INFO/SystemServer(49): Starting Sensor Service.
11-12 14:26:51.456: INFO/SystemServer(49): Starting Window Manager.
11-12 14:26:51.536: INFO/EventHub(49): New device: path=/dev/input/event0 name=qwerty2 id=0x10000 (of 0x1) index=1 fd=43 classes=0x7
11-12 14:26:51.536: INFO/EventHub(49): New keyboard: publicID=65536 device->id=65536 devname='qwerty2 propName='hw.keyboards.65536.devname' keylayout='/system/usr/keylayout/qwerty.kl'
11-12 14:26:51.556: INFO/SystemServer(49): Registering null Bluetooth Service (emulator)
11-12 14:26:51.565: ERROR/EventHub(49): could not get driver version for /dev/input/mouse0, Not a typewriter
11-12 14:26:51.575: ERROR/System(49): Failure starting core service
11-12 14:26:51.575: ERROR/System(49): java.lang.SecurityException
11-12 14:26:51.575: ERROR/System(49):     at android.os.BinderProxy.transact(Native Method)
11-12 14:26:51.575: ERROR/System(49):     at android.os.ServiceManagerProxy.addService(ServiceManagerNative.java:146)
11-12 14:26:51.575: ERROR/System(49):     at android.os.ServiceManager.addService(ServiceManager.java:72)
11-12 14:26:51.575: ERROR/System(49):     at com.android.server.ServerThread.run(SystemServer.java:155)
11-12 14:26:51.575: ERROR/AndroidRuntime(49): Crash logging skipped, no checkin service
11-12 14:26:51.575: INFO/SystemServer(49): Starting Status Bar Service.
11-12 14:26:51.598: ERROR/EventHub(49): could not get driver version for /dev/input/mice, Not a typewriter
11-12 14:26:51.598: INFO/KeyInputQueue(49): Device added: id=0x0, name=qwerty2, classes=7
11-12 14:26:51.598: INFO/KeyInputQueue(49):   X: unknown values
11-12 14:26:51.598: INFO/KeyInputQueue(49):   Y: unknown values
11-12 14:26:51.598: INFO/KeyInputQueue(49):   Pressure: unknown values
11-12 14:26:51.598: INFO/KeyInputQueue(49):   Size: unknown values
11-12 14:26:51.775: INFO/WindowManager(49): Input configuration changed: { scale=1.0 imsi=0/0 locale=en_US touch=3 key=2/2 nav=3 orien=1 }
11-12 14:26:51.977: ERROR/SystemServer(49): Failure starting StatusBarService
11-12 14:26:51.977: ERROR/SystemServer(49): java.lang.NullPointerException
11-12 14:26:51.977: ERROR/SystemServer(49):     at com.android.server.status.StatusBarPolicy.updateBluetooth(StatusBarPolicy.java:749)
11-12 14:26:51.977: ERROR/SystemServer(49):     at com.android.server.status.StatusBarPolicy.<init>(StatusBarPolicy.java:282)
11-12 14:26:51.977: ERROR/SystemServer(49):     at com.android.server.status.StatusBarPolicy.installIcons(StatusBarPolicy.java:337)
11-12 14:26:51.977: ERROR/SystemServer(49):     at com.android.server.ServerThread.run(SystemServer.java:186)
11-12 14:26:51.986: ERROR/AndroidRuntime(49): Crash logging skipped, no checkin service
11-12 14:26:51.986: INFO/SystemServer(49): Starting Hardware Service.
11-12 14:26:51.986: INFO/SystemServer(49): Starting NetStat Service.
11-12 14:26:51.996: INFO/SystemServer(49): Starting Connectivity Service.
11-12 14:26:51.996: INFO/jdwp(49): received file descriptor 49 from ADB
11-12 14:26:52.086: DEBUG/WifiService(49): WifiService starting up with Wi-Fi disabled
11-12 14:26:52.127: INFO/SystemServer(49): Starting Notification Manager.
11-12 14:26:52.137: INFO/SystemServer(49): Starting DeviceMemoryMonitor service
11-12 14:26:52.167: INFO/SystemServer(49): Starting Location Manager.
11-12 14:26:52.167: DEBUG/LocationManagerService(49): Constructed LocationManager Service
11-12 14:26:52.236: DEBUG/libhardware(49): using QEMU GPS Hardware emulation
11-12 14:26:52.246: ERROR/GpsLocationProvider(49): Could not open GPS configuration file /etc/gps.conf
11-12 14:26:52.246: ERROR/GpsLocationProvider(49): java.io.FileNotFoundException: /etc/gps.conf
11-12 14:26:52.246: ERROR/GpsLocationProvider(49):     at org.apache.harmony.luni.platform.OSFileSystem.open(OSFileSystem.java:227)
11-12 14:26:52.246: ERROR/GpsLocationProvider(49):     at java.io.FileInputStream.<init>(FileInputStream.java:76)
11-12 14:26:52.246: ERROR/GpsLocationProvider(49):     at com.android.internal.location.GpsLocationProvider.<init>(GpsLocationProvider.java:179)
11-12 14:26:52.246: ERROR/GpsLocationProvider(49):     at com.android.server.LocationManagerService._loadProvidersNoSync(LocationManagerService.java:356)
11-12 14:26:52.246: ERROR/GpsLocationProvider(49):     at com.android.server.LocationManagerService.loadProvidersNoSync(LocationManagerService.java:340)
11-12 14:26:52.246: ERROR/GpsLocationProvider(49):     at com.android.server.LocationManagerService.loadProviders(LocationManagerService.java:333)
11-12 14:26:52.246: ERROR/GpsLocationProvider(49):     at com.android.server.LocationManagerService.<init>(LocationManagerService.java:447)
11-12 14:26:52.246: ERROR/GpsLocationProvider(49):     at com.android.server.ServerThread.run(SystemServer.java:230)
11-12 14:26:52.256: ERROR/AndroidRuntime(49): Crash logging skipped, no checkin service
11-12 14:26:52.256: DEBUG/LocationManagerService(49): Found dir /data/location/gps
11-12 14:26:52.256: DEBUG/LocationManagerService(49): name = gps
11-12 14:26:52.266: DEBUG/GpsLocationProvider(49): enable
11-12 14:26:52.285: DEBUG/GpsLocationProvider(49): GpsEventThread starting
11-12 14:26:52.297: DEBUG/GpsLocationProvider(49): NetworkThread starting
11-12 14:26:52.297: DEBUG/GpsLocationProvider(49): NetworkThread wait for network
11-12 14:26:52.307: INFO/SystemServer(49): Starting Search Service.
11-12 14:26:52.316: INFO/SystemServer(49): Starting Clipboard Service.
11-12 14:26:52.316: INFO/SystemServer(49): Starting Checkin Service
11-12 14:26:52.696: DEBUG/dalvikvm(49): GC freed 4208 objects / 259584 bytes in 112ms
11-12 14:26:52.696: INFO/RecoverySystem(49): No recovery log file
11-12 14:26:52.696: INFO/RecoverySystem(49): No recovery intent file
11-12 14:26:52.796: WARN/CheckinService(49): No saved kernel log file
11-12 14:26:52.837: INFO/SystemServer(49): Starting Wallpaper Service
11-12 14:26:52.847: DEBUG/WallpaperService(49): WallpaperService startup
11-12 14:26:52.857: INFO/SystemServer(49): Starting Audio Service
11-12 14:26:53.056: INFO/SystemServer(49): Starting HeadsetObserver
11-12 14:26:53.065: WARN/HeadsetObserver(49): This kernel does not have wired headset support
11-12 14:26:53.075: INFO/WindowManager(49): Menu key state: 0
11-12 14:26:53.097: DEBUG/PowerManagerService(49): system ready!
11-12 14:26:53.117: DEBUG/ActivityManager(49): Start running!
11-12 14:26:53.216: INFO/Zygote(49): Process: zygote socket opened
11-12 14:26:53.235: INFO/ActivityManager(49): Start proc com.android.phone for added application com.android.phone: pid=88 uid=1001 gids={3001, 3003}
11-12 14:26:53.326: INFO/jdwp(88): received file descriptor 10 from ADB
11-12 14:26:53.356: INFO/ActivityManager(49): Starting activity: Intent { action=android.intent.action.MAIN categories={android.intent.category.HOME} flags=0x10000000 comp={com.android.launcher/com.android.launcher.Launcher} }
11-12 14:26:53.445: INFO/ActivityManager(49): Start proc android.process.acore for activity com.android.launcher/.Launcher: pid=94 uid=10002 gids={3003}
11-12 14:26:53.531: INFO/jdwp(94): received file descriptor 10 from ADB
11-12 14:26:53.945: INFO/ActivityThread(94): Publishing provider com.android.googlesearch.SuggestionProvider: com.android.googlesearch.SuggestionProvider
11-12 14:26:54.036: INFO/ActivityThread(88): Publishing provider mms-sms: com.android.providers.telephony.MmsSmsProvider
11-12 14:26:54.256: INFO/ActivityThread(88): Publishing provider mms: com.android.providers.telephony.MmsProvider
11-12 14:26:54.347: INFO/ActivityThread(88): Publishing provider telephony: com.android.providers.telephony.TelephonyProvider
11-12 14:26:54.366: INFO/ActivityThread(94): Publishing provider contacts;call_log: com.android.providers.contacts.ContactsProvider
11-12 14:26:54.398: INFO/ActivityThread(88): Publishing provider sms: com.android.providers.telephony.SmsProvider
11-12 14:26:54.486: INFO/ActivityThread(88): Publishing provider sim: com.android.phone.SimProvider
11-12 14:26:54.656: DEBUG/AndroidRuntime(103): >>>>>>>>>>>>>> AndroidRuntime START <<<<<<<<<<<<<<
11-12 14:26:54.656: DEBUG/AndroidRuntime(103): CheckJNI is ON
11-12 14:26:55.116: DEBUG/AndroidRuntime(103): --- registering native functions ---
11-12 14:26:55.116: INFO/jdwp(103): received file descriptor 20 from ADB
11-12 14:26:56.136: DEBUG/dalvikvm(49): GC freed 5221 objects / 249904 bytes in 596ms
11-12 14:26:56.387: DEBUG/PhoneApp(88): [PhoneIntfMgr] publish: com.android.phone.PhoneInterfaceManager@433a6ab8
11-12 14:26:56.416: DEBUG/dalvikvm(94): GC freed 1887 objects / 122816 bytes in 430ms
11-12 14:26:56.875: DEBUG/PhoneApp(88): Resetting audio state/mode: IDLE
11-12 14:26:57.516: DEBUG/KeyguardViewMediator(49): pokeWakelock(5000)
11-12 14:26:57.857: DEBUG/dalvikvm(94): GC freed 524 objects / 41432 bytes in 157ms
11-12 14:26:58.437: DEBUG/PackageParser(49): Scanning package: /data/app/vmdl16429.tmp
11-12 14:26:58.826: INFO/ActivityManager(49): Displayed activity com.android.launcher/.Launcher: 5416 ms
11-12 14:26:58.916: INFO/ActivityManager(49): Start proc com.google.process.gapps for on-hold: pid=124 uid=10014 gids={3003}
11-12 14:26:58.965: INFO/SurfaceFlinger(49): Boot is finished (10846 ms)
11-12 14:26:58.965: INFO/WindowManager(49): Input configuration changed: { scale=1.0 imsi=0/0 locale=en_US touch=3 key=2/2 nav=3 orien=1 }
11-12 14:26:59.406: DEBUG/dalvikvm(49): GC freed 4236 objects / 203128 bytes in 437ms
11-12 14:27:00.156: WARN/GoogleLoginService(124): Device has no accounts: sending Intent { action=android.accounts.LOGIN_ACCOUNTS_MISSING }
11-12 14:27:00.486: INFO/GoogleLoginService.PasswordEncrypter(124): no public key available, using default
11-12 14:27:00.675: INFO/ActivityManager(49): Stopping service: com.google.android.googleapps/.GoogleLoginService
11-12 14:27:00.706: WARN/PackageManager(49): Attempt to re-install anritsu.futuretechnologies.connectivity without first uninstalling.
11-12 14:27:00.745: INFO/installd(27): unlink /data/dalvik-cache/data@app@vmdl16429.tmp@classes.dex
11-12 14:27:00.777: DEBUG/AndroidRuntime(103): Shutting down VM
11-12 14:27:00.777: DEBUG/dalvikvm(103): DestroyJavaVM waiting for non-daemon threads to exit
11-12 14:27:00.787: INFO/dalvikvm(103): DestroyJavaVM shutting VM down
11-12 14:27:00.787: DEBUG/dalvikvm(103): HeapWorker thread shutting down
11-12 14:27:00.787: DEBUG/dalvikvm(103): HeapWorker thread has shut down
11-12 14:27:00.787: DEBUG/jdwp(103): JDWP shutting down net...
11-12 14:27:00.787: DEBUG/jdwp(103): +++ peer disconnected
11-12 14:27:00.787: INFO/dalvikvm(103): Debugger has detached; object registry had 1 entries
11-12 14:27:00.806: DEBUG/dalvikvm(103): VM cleaning up
11-12 14:27:00.806: DEBUG/dalvikvm(103): LinearAlloc 0x0 used 528972 of 4194304 (12%)
11-12 14:27:00.847: ERROR/dalvikvm(103): pthread_setspecific failed, err=22
11-12 14:27:01.276: DEBUG/dalvikvm(49): GC freed 3678 objects / 211880 bytes in 525ms
11-12 14:27:01.416: DEBUG/AndroidRuntime(138): >>>>>>>>>>>>>> AndroidRuntime START <<<<<<<<<<<<<<
11-12 14:27:01.416: DEBUG/AndroidRuntime(138): CheckJNI is ON
11-12 14:27:01.715: DEBUG/AndroidRuntime(138): --- registering native functions ---
11-12 14:27:02.956: DEBUG/PackageParser(49): Scanning package: /data/app/vmdl16430.tmp
11-12 14:27:03.166: DEBUG/PackageManager(49): Removing package anritsu.futuretechnologies.connectivity
11-12 14:27:03.166: DEBUG/PackageManager(49):   Activities: anritsu.futuretechnologies.connectivity.Connectivity
11-12 14:27:03.166: DEBUG/PackageManager(49): Scanning package anritsu.futuretechnologies.connectivity
11-12 14:27:03.166: INFO/PackageManager(49): /data/app/vmdl16430.tmp changed; unpacking
11-12 14:27:03.205: DEBUG/installd(27): DexInv: --- BEGIN '/data/app/vmdl16430.tmp' ---
11-12 14:27:03.526: DEBUG/dalvikvm(145): DexOpt: load 56ms, verify 63ms, opt 1ms
11-12 14:27:03.545: DEBUG/installd(27): DexInv: --- END '/data/app/vmdl16430.tmp' (success) ---
11-12 14:27:03.545: DEBUG/PackageManager(49):   Activities: anritsu.futuretechnologies.connectivity.Connectivity
11-12 14:27:03.687: INFO/installd(27): move /data/dalvik-cache/data@app@vmdl16430.tmp@classes.dex -> /data/dalvik-cache/data@app@anritsu.futuretechnologies.connectivity.apk@classes.dex
11-12 14:27:03.687: DEBUG/PackageManager(49): New package installed in /data/app/anritsu.futuretechnologies.connectivity.apk
11-12 14:27:03.965: DEBUG/ActivityManager(49): Uninstalling process anritsu.futuretechnologies.connectivity
11-12 14:27:03.987: DEBUG/AndroidRuntime(138): Shutting down VM
11-12 14:27:03.987: DEBUG/dalvikvm(138): DestroyJavaVM waiting for non-daemon threads to exit
11-12 14:27:04.006: INFO/dalvikvm(138): DestroyJavaVM shutting VM down
11-12 14:27:04.006: DEBUG/dalvikvm(138): HeapWorker thread shutting down
11-12 14:27:04.006: DEBUG/dalvikvm(138): HeapWorker thread has shut down
11-12 14:27:04.006: DEBUG/jdwp(138): JDWP shutting down net...
11-12 14:27:04.016: DEBUG/dalvikvm(138): VM cleaning up
11-12 14:27:04.026: DEBUG/dalvikvm(138): LinearAlloc 0x0 used 527548 of 4194304 (12%)
11-12 14:27:04.367: DEBUG/dalvikvm(94): GC freed 1743 objects / 94272 bytes in 368ms
11-12 14:27:04.505: DEBUG/dalvikvm(88): GC freed 2677 objects / 167744 bytes in 453ms
11-12 14:27:04.746: DEBUG/dalvikvm(49): GC freed 3533 objects / 192072 bytes in 461ms
11-12 14:27:04.777: DEBUG/AndroidRuntime(150): >>>>>>>>>>>>>> AndroidRuntime START <<<<<<<<<<<<<<
11-12 14:27:04.777: DEBUG/AndroidRuntime(150): CheckJNI is ON
11-12 14:27:05.187: DEBUG/AndroidRuntime(150): --- registering native functions ---
11-12 14:27:05.935: DEBUG/SystemClock(88): Setting time of day to sec=1226496417
11-12 14:26:57.868: WARN/SystemClock(88): Unable to set rtc to 1226496417: Invalid argument
11-12 14:26:58.287: DEBUG/PhoneApp(88): [CallNotifier] onMwiChanged(): false
11-12 14:26:58.317: DEBUG/PhoneApp(88): [CallNotifier] onCfiChanged(): false
11-12 14:26:58.748: INFO/ActivityManager(49): Starting activity: Intent { flags=0x10000000 comp={anritsu.futuretechnologies.connectivity/anritsu.futuretechnologies.connectivity.Connectivity} }
11-12 14:26:58.878: INFO/ActivityManager(49): Start proc anritsu.futuretechnologies.connectivity for activity anritsu.futuretechnologies.connectivity/.Connectivity: pid=158 uid=10018 gids={}
11-12 14:26:58.888: DEBUG/AndroidRuntime(150): Shutting down VM
11-12 14:26:58.888: DEBUG/dalvikvm(150): DestroyJavaVM waiting for non-daemon threads to exit
11-12 14:26:58.897: INFO/dalvikvm(150): DestroyJavaVM shutting VM down
11-12 14:26:58.907: DEBUG/dalvikvm(150): HeapWorker thread shutting down
11-12 14:26:58.907: DEBUG/dalvikvm(150): HeapWorker thread has shut down
11-12 14:26:58.907: DEBUG/jdwp(150): JDWP shutting down net...
11-12 14:26:58.938: DEBUG/dalvikvm(150): VM cleaning up
11-12 14:26:58.957: ERROR/dalvikvm(150): pthread_setspecific failed, err=22
11-12 14:26:58.957: DEBUG/dalvikvm(150): LinearAlloc 0x0 used 539340 of 4194304 (12%)
11-12 14:26:59.037: INFO/jdwp(124): received file descriptor 26 from ADB
11-12 14:26:59.099: INFO/jdwp(158): received file descriptor 10 from ADB
11-12 14:26:59.708: DEBUG/AndroidRuntime(158): Shutting down VM
11-12 14:26:59.708: WARN/dalvikvm(158): threadid=3: thread exiting with uncaught exception (group=0x40010e28)
11-12 14:26:59.708: ERROR/AndroidRuntime(158): Uncaught handler: thread main exiting due to uncaught exception
11-12 14:26:59.748: ERROR/AndroidRuntime(158): java.lang.RuntimeException: Unable to start activity ComponentInfo{anritsu.futuretechnologies.connectivity/anritsu.futuretechnologies.connectivity.Connectivity}: java.lang.NullPointerException
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2140)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2156)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at android.app.ActivityThread.access$1800(ActivityThread.java:112)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1580)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at android.os.Handler.dispatchMessage(Handler.java:88)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at android.os.Looper.loop(Looper.java:123)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at android.app.ActivityThread.main(ActivityThread.java:3742)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at java.lang.reflect.Method.invokeNative(Native Method)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at java.lang.reflect.Method.invoke(Method.java:515)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:739)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:497)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at dalvik.system.NativeStart.main(Native Method)
11-12 14:26:59.748: ERROR/AndroidRuntime(158): Caused by: java.lang.NullPointerException
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at anritsu.futuretechnologies.connectivity.Connectivity.onCreate(Connectivity.java:39)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1122)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2103)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     ... 11 more
11-12 14:26:59.797: DEBUG/dalvikvm(49): GC freed 2976 objects / 196544 bytes in 223ms
11-12 14:26:59.857: INFO/Process(49): Sending signal. PID: 158 SIG: 3
11-12 14:26:59.857: INFO/dalvikvm(158): threadid=7: reacting to signal 3
11-12 14:26:59.877: INFO/dalvikvm(158): Wrote stack trace to '/data/anr/traces.txt'
11-12 14:27:00.238: DEBUG/PhoneApp(88): [CallNotifier] onMwiChanged(): false
11-12 14:27:00.238: DEBUG/PhoneApp(88): [CallNotifier] onCfiChanged(): false
11-12 14:27:00.308: INFO/ActivityManager(49): Start proc com.android.mms for broadcast com.android.mms/.transaction.SmsReceiver: pid=166 uid=10008 gids={3003}
11-12 14:27:00.368: INFO/ActivityManager(49): processNextBroadcast: waiting for ProcessRecord{43495d28 166:com.android.mms/10008}
11-12 14:27:00.417: INFO/jdwp(166): received file descriptor 10 from ADB
11-12 14:27:00.538: WARN/StkAppInstaller(88): Could not change STK app state
11-12 14:27:00.599: DEBUG/TelephonyProvider(88): Setting numeric '310260' to be the current operator
11-12 14:27:01.028: INFO/ARMAssembler(49): generated scanline__00000077:03515104_00000000_00000000 [ 27 ipp] (41 ins) at [0x251970:0x251a14] in 2005562 ns
11-12 14:27:01.179: DEBUG/MobileDataStateTracker(49): CONNECTED event did not supply interface name.
11-12 14:27:01.179: DEBUG/MobileDataStateTracker(49): DNS server addresses are not known.
11-12 14:27:01.189: ERROR/NetworkStateTracker(49): Can't set tcp buffer sizes:java.io.FileNotFoundException: /sys/kernel/ipv4/tcp_rmem_min
11-12 14:27:01.247: DEBUG/GpsLocationProvider(49): updateNetworkState available
11-12 14:27:01.347: INFO/ActivityManager(49): Start proc com.android.alarmclock for broadcast com.android.alarmclock/.AlarmInitReceiver: pid=174 uid=10000 gids={}
11-12 14:27:01.368: INFO/ActivityManager(49): Stopping service: com.android.mms/.transaction.SmsReceiverService
11-12 14:27:01.388: DEBUG/GpsLocationProvider(49): NetworkThread out of wake loop
11-12 14:27:01.388: DEBUG/GpsLocationProvider(49): Requesting time from NTP server pool.ntp.org
11-12 14:27:01.438: INFO/jdwp(174): received file descriptor 10 from ADB
11-12 14:27:01.547: INFO/ActivityManager(49): processNextBroadcast: waiting for ProcessRecord{4347dec0 174:com.android.alarmclock/10000}
11-12 14:27:01.547: INFO/CheckinService(49): Checkin triggered: Intent { action=android.server.checkin.CHECKIN flags=0x4 (has extras) }
11-12 14:27:01.547: INFO/CheckinService(49): Checkin disabled by system property
11-12 14:27:01.618: INFO/ActivityThread(174): Publishing provider com.android.alarmclock: com.android.alarmclock.AlarmProvider
11-12 14:27:01.817: DEBUG/SntpClient(49): round trip: 212 ms
11-12 14:27:01.817: DEBUG/SntpClient(49): clock offset: 25088 ms
11-12 14:27:01.817: DEBUG/GpsLocationProvider(49): calling native_inject_time: 1226496446696 reference: 35041 certainty: 106
11-12 14:27:01.817: DEBUG/GpsLocationProvider(49): NetworkThread wait for 14400000ms
11-12 14:27:01.967: DEBUG/dalvikvm(49): GC freed 3544 objects / 159096 bytes in 104ms
11-12 14:27:02.028: INFO/ActivityManager(49): Start proc android.process.media for broadcast com.android.providers.downloads/.DownloadReceiver: pid=183 uid=10003 gids={1006, 3003, 2001}
11-12 14:27:02.068: INFO/jdwp(183): received file descriptor 10 from ADB
11-12 14:27:02.217: INFO/ActivityThread(183): Publishing provider downloads: com.android.providers.downloads.DownloadProvider
11-12 14:27:02.238: INFO/ActivityThread(183): Publishing provider drm: com.android.providers.drm.DrmProvider
11-12 14:27:02.268: INFO/ActivityThread(183): Publishing provider media: com.android.providers.media.MediaProvider
11-12 14:27:02.318: VERBOSE/MediaProvider(183): Attached volume: internal
11-12 14:27:02.587: DEBUG/MediaScannerService(183): start scanning volume internal
11-12 14:27:03.359: INFO/ActivityManager(49): Stopping service: com.android.mms/.transaction.TransactionService
11-12 14:27:03.497: INFO/ActivityManager(49): Stopping service: com.android.providers.downloads/.DownloadService
11-12 14:27:03.548: DEBUG/MediaScanner(183):  prescan time: 599ms
11-12 14:27:03.548: DEBUG/MediaScanner(183):     scan time: 309ms
11-12 14:27:03.567: DEBUG/MediaScanner(183): postscan time: 1ms
11-12 14:27:03.567: DEBUG/MediaScanner(183):    total time: 909ms
11-12 14:27:03.577: DEBUG/MediaScannerService(183): done scanning volume internal
11-12 14:27:03.577: INFO/ActivityManager(49): Stopping service: com.android.providers.media/.MediaScannerService
11-12 14:27:03.618: INFO/ActivityManager(49): Stopping service: com.android.mms/.transaction.SmsReceiverService
11-12 14:27:06.298: WARN/KeyCharacterMap(49): No keyboard for id 0
11-12 14:27:06.298: WARN/KeyCharacterMap(49): Using default keymap: /system/usr/keychars/qwerty.kcm.bin
11-12 14:27:06.298: DEBUG/KeyguardViewMediator(49): pokeWakelock(5000)
11-12 14:27:08.057: INFO/Process(158): Sending signal. PID: 158 SIG: 9
11-12 14:27:08.069: INFO/ActivityManager(49): Process anritsu.futuretechnologies.connectivity (pid 158) has died.
11-12 14:27:13.368: DEBUG/dalvikvm(88): GC freed 3619 objects / 189712 bytes in 82ms



Error:
Code: Select all
11-12 14:26:39.736: ERROR/mountd(19): could not read initial mass storage state
11-12 14:26:40.027: ERROR/flash_image(28): can't find recovery partition
11-12 14:26:48.115: ERROR/MemoryHeapBase(49): error opening /dev/pmem: No such file or directory
11-12 14:26:48.127: ERROR/SurfaceFlinger(49): Couldn't open /sys/android_power/wait_for_fb_sleep or /sys/android_power/wait_for_fb_wake
11-12 14:26:48.167: ERROR/GLLogger(49): couldn't load <libhgl.so> library (Cannot find library)
11-12 14:26:48.225: ERROR/GLLogger(49): couldn't load <libhgl.so> library (Cannot find library)
11-12 14:26:51.325: ERROR/BatteryService(49): Could not open '/sys/class/power_supply/usb/online'
11-12 14:26:51.325: ERROR/BatteryService(49): Could not open '/sys/class/power_supply/battery/batt_vol'
11-12 14:26:51.325: ERROR/BatteryService(49): Could not open '/sys/class/power_supply/battery/batt_temp'
11-12 14:26:51.565: ERROR/EventHub(49): could not get driver version for /dev/input/mouse0, Not a typewriter
11-12 14:26:51.575: ERROR/System(49): Failure starting core service
11-12 14:26:51.575: ERROR/System(49): java.lang.SecurityException
11-12 14:26:51.575: ERROR/System(49):     at android.os.BinderProxy.transact(Native Method)
11-12 14:26:51.575: ERROR/System(49):     at android.os.ServiceManagerProxy.addService(ServiceManagerNative.java:146)
11-12 14:26:51.575: ERROR/System(49):     at android.os.ServiceManager.addService(ServiceManager.java:72)
11-12 14:26:51.575: ERROR/System(49):     at com.android.server.ServerThread.run(SystemServer.java:155)
11-12 14:26:51.575: ERROR/AndroidRuntime(49): Crash logging skipped, no checkin service
11-12 14:26:51.598: ERROR/EventHub(49): could not get driver version for /dev/input/mice, Not a typewriter
11-12 14:26:51.977: ERROR/SystemServer(49): Failure starting StatusBarService
11-12 14:26:51.977: ERROR/SystemServer(49): java.lang.NullPointerException
11-12 14:26:51.977: ERROR/SystemServer(49):     at com.android.server.status.StatusBarPolicy.updateBluetooth(StatusBarPolicy.java:749)
11-12 14:26:51.977: ERROR/SystemServer(49):     at com.android.server.status.StatusBarPolicy.<init>(StatusBarPolicy.java:282)
11-12 14:26:51.977: ERROR/SystemServer(49):     at com.android.server.status.StatusBarPolicy.installIcons(StatusBarPolicy.java:337)
11-12 14:26:51.977: ERROR/SystemServer(49):     at com.android.server.ServerThread.run(SystemServer.java:186)
11-12 14:26:51.986: ERROR/AndroidRuntime(49): Crash logging skipped, no checkin service
11-12 14:26:52.246: ERROR/GpsLocationProvider(49): Could not open GPS configuration file /etc/gps.conf
11-12 14:26:52.246: ERROR/GpsLocationProvider(49): java.io.FileNotFoundException: /etc/gps.conf
11-12 14:26:52.246: ERROR/GpsLocationProvider(49):     at org.apache.harmony.luni.platform.OSFileSystem.open(OSFileSystem.java:227)
11-12 14:26:52.246: ERROR/GpsLocationProvider(49):     at java.io.FileInputStream.<init>(FileInputStream.java:76)
11-12 14:26:52.246: ERROR/GpsLocationProvider(49):     at com.android.internal.location.GpsLocationProvider.<init>(GpsLocationProvider.java:179)
11-12 14:26:52.246: ERROR/GpsLocationProvider(49):     at com.android.server.LocationManagerService._loadProvidersNoSync(LocationManagerService.java:356)
11-12 14:26:52.246: ERROR/GpsLocationProvider(49):     at com.android.server.LocationManagerService.loadProvidersNoSync(LocationManagerService.java:340)
11-12 14:26:52.246: ERROR/GpsLocationProvider(49):     at com.android.server.LocationManagerService.loadProviders(LocationManagerService.java:333)
11-12 14:26:52.246: ERROR/GpsLocationProvider(49):     at com.android.server.LocationManagerService.<init>(LocationManagerService.java:447)
11-12 14:26:52.246: ERROR/GpsLocationProvider(49):     at com.android.server.ServerThread.run(SystemServer.java:230)
11-12 14:26:52.256: ERROR/AndroidRuntime(49): Crash logging skipped, no checkin service
11-12 14:27:00.847: ERROR/dalvikvm(103): pthread_setspecific failed, err=22
11-12 14:26:58.957: ERROR/dalvikvm(150): pthread_setspecific failed, err=22
11-12 14:26:59.708: ERROR/AndroidRuntime(158): Uncaught handler: thread main exiting due to uncaught exception
11-12 14:26:59.748: ERROR/AndroidRuntime(158): java.lang.RuntimeException: Unable to start activity ComponentInfo{anritsu.futuretechnologies.connectivity/anritsu.futuretechnologies.connectivity.Connectivity}: java.lang.NullPointerException
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2140)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2156)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at android.app.ActivityThread.access$1800(ActivityThread.java:112)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1580)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at android.os.Handler.dispatchMessage(Handler.java:88)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at android.os.Looper.loop(Looper.java:123)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at android.app.ActivityThread.main(ActivityThread.java:3742)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at java.lang.reflect.Method.invokeNative(Native Method)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at java.lang.reflect.Method.invoke(Method.java:515)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:739)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:497)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at dalvik.system.NativeStart.main(Native Method)
11-12 14:26:59.748: ERROR/AndroidRuntime(158): Caused by: java.lang.NullPointerException
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at anritsu.futuretechnologies.connectivity.Connectivity.onCreate(Connectivity.java:39)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1122)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2103)
11-12 14:26:59.748: ERROR/AndroidRuntime(158):     ... 11 more
11-12 14:27:01.189: ERROR/NetworkStateTracker(49): Can't set tcp buffer sizes:java.io.FileNotFoundException: /sys/kernel/ipv4/tcp_rmem_min



But I noticed the thing that causes the problem is the buttonlistener that refers to a button that is in a different xml file than the one that is set at the start. It seems that's the problem since if I comment out that code it works, but I just want to be able to click my way from layout file to layout file, like a normal menu :)

Anyway, here's some of the logcat.
KanedaSyndrome
Developer
Developer
 
Posts: 41
Joined: Tue Nov 11, 2008 3:32 pm

Postby MrSnowflake » Wed Nov 12, 2008 3:04 pm

On line 39 a nullpointer exception occurs. I guess R.id.backbutton1 or R.id.button1 don't exist in you current contentView. To solve this preload each view:
Syntax: [ Download ] [ Hide ]
Using java Syntax Highlighting
  1. View mainLayout = View.inflate(this, R.layout.main, null);
  2.  
  3. View menuPoint = View.inflate(this, R.layout.menupoint1, null);
  4.  
  5. Btton backbutton1 = (Button)menuPoint.findViewById(R.id.button_back1);
  6.  
  7. Button button1 = (Button)main.findViewById(R.id.button1);
Parsed in 0.035 seconds, using GeSHi 1.0.8.4


But actually in this case it would be better to use a ViewAnimator such as a ViewSwitcher. This view lets you switch between 2 layouts, and you can preform some animations between them.
User avatar
MrSnowflake
Moderator
Moderator
 
Posts: 1439
Joined: Sat Feb 16, 2008 3:11 pm
Location: Flanders, Belgium

Postby KanedaSyndrome » Mon Nov 17, 2008 2:13 pm

ok thanks, now it will allow me to run the program, but doing the
Code: Select all
(Button)main.findViewById(R.id.button1);
bit breaks the onclicklisteners for some reason. Once I put the "main." infront of "findViewById" the buttons stop working.

Here's the relevant bit of my code:

Code: Select all
        View main = View.inflate(this, R.layout.main, null);
        View menupoint1 = View.inflate(this, R.layout.menupoint1, null);
       
        Button backbutton1 = (Button)menupoint1.findViewById(R.id.button_back1);
        Button button1 = (Button)main.findViewById(R.id.button1);
        Button button2 = (Button)main.findViewById(R.id.button2);
                       
        button1.setOnClickListener(new OnClickListener()
        {
            public void onClick(View viewParam)
            {
               setContentView(R.layout.menupoint1);
            }
       
        });
       
        button2.setOnClickListener(new OnClickListener()
        {
            public void onClick(View viewParam)
            {
               setContentView(R.layout.menupoint1);
            }
       
        });
       
        //this part bugs the program for some reason.
        backbutton1.setOnClickListener(new OnClickListener()
        {
            public void onClick(View viewParam)
            {
               setContentView(R.layout.main);
            }
        });


I don't understand it since the buttons and their placements are still placed in the same name variables and thus they should react to button clicks still no?

Btw, a ViewSwitcher wont work since ultimately I will have more than just two layout that I cycle through as I create this UI menu.
KanedaSyndrome
Developer
Developer
 
Posts: 41
Joined: Tue Nov 11, 2008 3:32 pm

Postby MrSnowflake » Mon Nov 17, 2008 4:24 pm

KanedaSyndrome wrote:ok thanks, now it will allow me to run the program, but doing the
Code: Select all
(Button)main.findViewById(R.id.button1);
bit breaks the onclicklisteners for some reason. Once I put the "main." infront of "findViewById" the buttons stop working.
Strange, don't se the error... Check you log, maybe there's some more info.

KanedaSyndrome wrote: Btw, a ViewSwitcher wont work since ultimately I will have more than just two layout that I cycle through as I create this UI menu.
If ViewSwitcher isn't good enough, use ViewAnimator.
User avatar
MrSnowflake
Moderator
Moderator
 
Posts: 1439
Joined: Sat Feb 16, 2008 3:11 pm
Location: Flanders, Belgium

Top

Postby MrSnowflake » Wed Dec 10, 2008 3:19 pm

I think I've found it: instead of setContentView(R.layout.main); do setContentView(menupoint1);

And of course the same for the other 2 setcontentViews.
User avatar
MrSnowflake
Moderator
Moderator
 
Posts: 1439
Joined: Sat Feb 16, 2008 3:11 pm
Location: Flanders, Belgium

Postby KanedaSyndrome » Wed Dec 10, 2008 3:20 pm

oh thanks, will try that out.. thought I had to specify the path to the XML?
KanedaSyndrome
Developer
Developer
 
Posts: 41
Joined: Tue Nov 11, 2008 3:32 pm

Postby MrSnowflake » Wed Dec 10, 2008 3:22 pm

Well yes, but you already inflated the xml, and when you inflate it again, it will create new instances of the buttons, so your backbutton won't work in the currently selected, newly inflated xml layout.
User avatar
MrSnowflake
Moderator
Moderator
 
Posts: 1439
Joined: Sat Feb 16, 2008 3:11 pm
Location: Flanders, Belgium

Postby KanedaSyndrome » Fri Dec 19, 2008 2:40 pm

Thanks a lot for your help snow, I had time to look it over again today, and it worked.

I am wondering if I should make a short tutorial for all the noobs out there like me that have trouble getting started with this stuff.

Thanks again.

~Kan
KanedaSyndrome
Developer
Developer
 
Posts: 41
Joined: Tue Nov 11, 2008 3:32 pm

Postby KanedaSyndrome » Mon Dec 22, 2008 3:41 pm

Now that this works,

I really just need to know how to get this stuff onto my device.

I am not using a G1, but a N810 with that special "hack" Android on it. I know from a fact that it's possible since I have heard from my supervisor that some polish dudes got it working before me on a similar project. I just don't know how to get Android to recognize the damn apps..

So having a bit probs with that, any help would be appreciated.

I am using Win XP pro SP3
KanedaSyndrome
Developer
Developer
 
Posts: 41
Joined: Tue Nov 11, 2008 3:32 pm

Postby MrSnowflake » Mon Dec 22, 2008 3:48 pm

This is a not related question, so start a new thread in the correct sub-forum please.
User avatar
MrSnowflake
Moderator
Moderator
 
Posts: 1439
Joined: Sat Feb 16, 2008 3:11 pm
Location: Flanders, Belgium

Top

Return to View, Layout & Resource Problems

Who is online

Users browsing this forum: No registered users and 5 guests