I just used this getDeviceId() to retrieve the unique id of the phone, but in the emulator it gives 00000000 when I try to display it. I know it makes sense to do that but can I spoof a device id for testing purposes. I need to setup about 4 -5 android devices in my emulator to check the functionality of the app that I have written, and the entire app revolves around the unique id of the mobile device. I just feel, maybe it should be there in the DDMS but I am not able to figure it out.
I have developed and tested my app on the emulator, and now want to install it on my HTC device. the apk installs successfully, however my database is not going with it. I have created my database using sqliteman browser b/c I have to insert a bulk data before the app starts. I have four tables in my db and call each in different activities and created all on the sqliteman. after the data is inserted I pull back the db onto the data folder of the emulator. it works perfect on the emulator but failed on the device. when I try to pull my db on the real device, it shows access denied problem
I've been trying to get this to work for a few days without success. Basically, I'm writing a small test app to make the phone report it's position as somewhere else using addTestProvider and setTestProviderLocation etc. Basically it looks fine and appears to report its location as having changed, however Google Maps etc. seems to still be querying the real GPS provider. Does anyone have any ideas how to get around this?
This isn't an app that will actually be used for anything, it's just really to satisfy my own curiosity and gain an understanding.
How to know if the application is running on emulator or on a real device? I want to implement a function to detect wifi connection. If the application is running on emulator, just skip the wifi detection, while on real device, the wifi connection check should be done. how to do that?
Am developed one application .The UI get varying differently in emulator and device.the correct ui displayed in emulator but in device the button size, spinner size,text view all changing deterrently in device.So i have to change some modification in xml file according to the device visibility. any one help me How can i fixed the same xml for device and emulator which both UI display cannot change.what are the things i have to include in my project to fix the same display for emulator and device.
I developed a game. On the emulator (not froyo) I am getting like less than 10 fps. But on my Nexus One with froyo I am getting 50 fps. Is this normal? Which one should I trust, I want my game to perform good on phones without froyo
When trying to run my application on the emulator I get an error from the activitymanager: ActivityManager: Error type 3 My activity exists, is listed in the manifest (in fact, its the MAIN launcher activity).
This is a HOW TO about how to spoof your MAC address. A MAC address is a combination of numbers and letters that are unique to your own wifi card. I am not responsible for how you use this, I am just putting it out here. Don't flood this thread with how it is illegal because there are legal uses for this (such as pen testing).
First, you need to download a free app called Android Terminal Emulator. It is free and works on the Incredible. You do not need root for this to work. To change back to your normal MAC Address, just follow these steps to change it back or restart your phone.
It makes this easier if you already know your real MAC Address which can be found at: All Programs > Settings > Wireless & Networks > WiFi Settings > Menu button > Advanced
Keep this in mind
Then, open the Terminal Emulator previously installed. You need to run a few linux commands to get the change. You need to find the name of your card. To do this type this without the quotes (''): 'ip link show'
This will provide a list of a bunch of different interfaces. Find the one that has the same MAC address as the one found above. On the Incredible, it is the last one called eth0. I will use eth0 in the examples, but if it is different, then change eth0 to your own one in the following commands.
To change the MAC Address, type this without the quotes (''): 'ip link set eth0 address XX:XX:XX:XX:XX:XX' 'ip link set eth0 broadcast XX:XX:XX:XX:XX:XX'
XX:XX:XX:XX:XX:XX is the new MAC Address you want where each X is a letter A-F or number.
Finally, to check if the MAC Address has changed, type this without the quotes (''): 'ip link show eth0'
It should now show the new MAC Address. I haven't checked if it sends this MAC address to the router, but I think it will. I will update once I check it.
Is there a way to check if our code is running in the emulator vs a real device? I'm using a Map View which requires a signing key. I'm using the signature of the eclipse debug key when running on the emulator, but this won't work when I build a release version. I think I need to have a check to see if I'm running on a real device, and set it to the real release key at that time.
I am trying to actually simulate a vibrator device inside the emulator .A timed_output driver for the vibrator was created and i am able to access the node at /sys/class/timed_output/vibrator/enable that is specified as THE_DEVICE in the vibrator.c file at hardware/ libhardware/vibrator/.The driver is tested to work from the kernel below. I ran into some issue while trying to invoke the driver from a user level app.I just added these two lines and created an app.
I am working on an application where i will track the movement of the android device inside a building... suppose i display a map of the building in the android emulator... Now,i need to simulate the movement of the android device.... is there a way in which i can control the movement of the android device and see the real time movement of the device in the map ... like a dot moving in the map .... Is this possible to do using the android emulator? when i googled this requirement, i came across SensorSimulator...But,this software shows the acceleration,magnetic field and temperature values... It doesnt display the co-ordinate values....
I'm using the 1.5 SDK. I read in 1.0 that rotating the device would cause onCreate() to be called in our apps (possibly recreating the entire app?). Is there a way to test rotating the device in the emulator? I just want to see what happens, I don't have a device to test this. Will the behavior be the same for 1.5 as it was in 1.0?
Is there a simple way to detect that your code is running on the android emulator and not on a real device? I want to work around differences between emulator + real, e.g. with respect to network connectivity detection.
I am developing an application which I need to test in Samsung I9000 whose resolution is 480*800. But when I try to create a AVD Emulator with 480*800 resolution, I am getting a very big resolution. How to get the screen resolution of Emulator similar to Device. I will be waiting for valuable reply.
Did anyone encounter this problem? Particularly, I have a dialog style themes for a few activities and these come up as expected on the emulator, but are full screen on the device. The theme I a using is actually an extension of the basic dialog theme (Theme.Dialog). I did not check with the original one.
Today, I want to measure the Wi-Fi signal quality. So I download the Wi-Fi Analyzer app, and I install it on the emulator,but it showed that the Wi-Fi has not been turned on. Thus I turn it on, but it still shows errors.
I tried several times but it is still not working.
I just had an issue with my Facebook account and bogus messages sent ostensibly from me to my "friends." The only thing that changed recently from my end was getting the Droid and activating the Facebook app on it. Probably coincidence, but . . . has anyone else had this issue?
I am working on a compute intensive app for Android. I do not have any device yet to test performance. However, the performance on emulator is a bit slower than expected. I see an old question about some estimation of emulator vs device. What are your experiences while developing apps with recent SDK Froyo/2.2. Is performance observed on emulator is slower than actual device. Please share your experience and the specs of your dev machine and mobile devices, both.
I have added a second Virtual Device to test a different screen resolution (QVGA), but now I wanna switch back to the first AVD (HVGA) again. How can I set the virtual device in Eclipse to be used by default or even specifically for my project? In the properties I can only set the API level. I also couldn't find any information in the command line tool documentation to set this manually.
Does anyone know how to get the eclipse logcat output to switch from emulator to device and back again? I am often developing, and using emulator and device in tandem, mainly because I can trace the http comms on the emulator and not on the device, and logcat gets stuck on whichever is launched first from eclipse. Right now the only way to get logcat output switched over is to restart eclipse, which is a little time-consuming. Anyone know another way to achieve the same thing?
I have tried to replicate the Transparency/Translucency effects created in the API Demo(which works flawlessly) and the code i wrote works on the emulator but not on my actual device(Google ION)I copied the styles and colors.xml files from the API demos code and set the theme of my activity I want to be transparent to "@style/ Theme.Transparent" in my activity i set my content view to a layout which contains only a TextView containing : <TextView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/text" android:layout_width="fill_parent" android:layout_height="fill_parent" android:gravity="center_vertical|center_horizontal" android:text="should have transparent background" /> i have also tried setting the theme using: setTheme (R.style.Theme_Transparent).
i am writing a widget and trying to prove that it doesn't run when the phone is in deep sleep as i am setting an alarm with type ELAPSED_REALTIME. when i hit the end call on the emulator the device screen goes blank, but i still see my alarms being delivered. am i missing something?
I have an SQL lite database that I am trying to copy to the device. I was able to copy it to the emulator easily using DDMS however with the protection in the device, I cannot access the database files from the DDMS perspective.
I read many attempts here but couldn't find an easy solution.
Is there any way to attach the database (let's say named 'proj') and replace the currently created database proj in he device files?
I have a test project with a WebView that displays a html page (demo.html) stored in the assets folder. I've stored images and databases in the assets folder before without any problem, but for some reason now that assets aren't being seen. The code I'm using is as follows;
I developed a custom content provider for extracting data from zip files. The provider works properly in the emulator but when I run the apk on the device I get no content provider followed by the url The manifest says (outside the application tag
Just got a notification on my Galaxy 10.1 tab: "Sign-in error for [URL]... - Touch to sign into your account".
Is it possible that this is malware spoofing the system? Any way for me to find out? I've run Avira and it says the tab's clean, and I also checked the running services, but I don't see anything out of the ordinary.
I'm wary because a few days ago I got a notification that my tablet had a virus *eyeroll* and when I tapped it it went to a 'download antivirus here' page which of course I didn't click on...
I'd like to use a 1x1 size Nine-patch image from Android drawable resources. When I'm trying to display it with <ImageView> in my layout xml file, this one is never showing up on the Android emulator device. Here's the xml code below. Code...
Texture appears white in the real device but not in the emulator, Ive already tried to find the solution in other POSTS but none of the solutions worked. The problem that I have is that the loaded texture not displayed in the real device (G1, firmware 1.5). If I turn of the texture and put a color in the geometry, it works fine. Details: the file that Im loading has width and height power of 2. And I tried with .bmp and .png files, for both I had the same problem. My code: METHOD used to load texture: private int loadTexture (GL10 gl, Bitmap bmp) int tmp_tex= new int; gl.glGenTextures(1, tmp_tex, 0.
I implemented an application which will add contacts. It is working in emulator perfectly. I have android 2.0.1 device I am checking in that device but it is not adding contacts to contact list. I have given necessary permissions like write contacts.
I am trying to create an app that gets the location and telephone number of the phone. This is the Code I am using to get the telephone number (I am focusing on sdk 1.5) and in the emulator this works.