My app seldom needs to put the device (or screen) to sleep. That is - programmatically imitate user pressing on red stop-call button. According to docs PowerManager.goToSleep() does just that, but requires android.permission.DEVICE_POWER, which is never granted to apps!
(A) What on earth should I do to get this working? (B) How can I programmatically wake up the device.
just to clarify - I'm not interested in a wake lock solution.
I tried the market and searched google (only to find apps that help you sleep lol). I'm looking for a way to set a button on the home screen to press and put the phone to sleep instead of having to push the top button all the time.
Usually the phone is awake, and when you lower it the phone lights up for numeric input (love that feature).
But after a minute or so it locks. You have to push power button before you can enter numbers- annoying. Is there a "keep alive" option I'm not seeing?
On a similar note, is there a way to make the phone lock automatically (like an app)? It's also annoying to have to manually lock it: I'd rather keep waking it up (if it was indeed idle and not running a program) than forget to lock it and dial/message everyone in my contact list from my pocket.
Can anyone tell me please how can i make screen shorts with an android device. I have to test an application,and to make screen shorts on it. and i need and screen short tool that will run in the background, while i am running my application. Is it possible. Please give me an advice, a link where i can find this kind of the application
my application objective is to save location updates every ,let say, 20 minuets .I used service and it worked fine , but when i lock the screen or it is locked automatically the service stop running .when i unlock it , service runs again.How to make my code run all the time in all conditions?
I have a game out on Android, and it runs in a single thread. Performs the work in run() and the draws in onDraw().Pretty simple.However, on a Droid it runs much faster than on a G1.What is a best practice for ensuring that the game runs at the same speed regardless of the device?
I need to use this for a Samsung Tablet.Usually if the device is switched-off and the USB cable is being connected the display will wake up for some seconds showing an animated battery.Instead I want to let it boot.I suspect this is close to the metal. Where do I have to make a modification?In the kernel, in the Android platform, or is this hidden in some proprietary code of the manufacturer?
How to make exact copy of my device on Android SDK so that I can test and develop roms on it? I found a guide on xda but it shows how to emulate Xperia X10 and it needs an add-on for X10. But there is no add-on for my device, so how can I emulate it manually? I have a Karbonn ST10 tablet.
My fiends (Electronic engineers) want to assemble a new tablet, they asked me to research about making a ROM for that.Now, I need some resources to know about making a new ROM with custom kernel for our device.
is there any permissions from Google if we want to sell our device?
I apologize if these topics were already covered in previous threads.I wasn't able to find anything related in my searches. Auto-rotation for keyboard when answering a text message received in sleep mode does not work. If I actively send a text when phone is already awake, keyboard rotates with no problem but when I go to reply to a text that I received while phone is in sleep mode, the keyboard does not rotate. Is this the norm?I am also experiencing a delay when the I wake the phone. After unlocking the phone, I used to go straight to my home page, now I get a "loading" message which takes several seconds. Is this due to the number of apps I have loaded? Is it possibly due to number of photo frames I have on my home screen or the complexity of the wallpaper?
Just got the S4. Had the Incredible. Want to make my incredible, basically, a touch device for my kids (Wi-fi) only. So (after posting this question on the verizon forums) I performed a factory reset on my phone (erased all data) in order to start with a clean phone. When it comes back up it wants me to activate the phone. Is there anyway around this? Or do I have to activate the incredible and then reactivate my S4?
.My phone isnt detected by ADB during its boot. After bootup it shows up in the list of attached devices. Im trying to port MIUI v4 to my device so I need a logcat during the boot because it just hangs at the bootanimation but ADB doesnt see my device during boot. If I force a logcat, the log is emply.
I have tried several ROMs and on both Windows and Ubuntu and still no result.
I have a bootloop in the spaash logo,i was updating my software. My phone its an LG p714
i was trying to make a CWM recovery for the device. i managed to flash the CWM recovery but i was unable to access to,i was getting Secure booting Error,but the phone booted as normally does,well i has a notification to update the software via OTA,so i decide to update it,but before that i downloaded OTA root keeper,in order to keep root,made the SU backup and unrooted the phone,after i tought,well im ok i update the phone then i keep the root,but i forgot that i have flashed th eimage with the CMW recovery,so i got stuck in bootloop,and by the way if i connect the phone via USB and turned off i enter into CMW recovery, strange,but i cant do anything,i cant flash via KDZ i can use ADB but i dont have SU permissions.
Can someone explain a couple of very simple concepts to me - I'm interested in mobile devices running android and how they are identified over networks. Some scenarios: Device is connected over WiFi - presumably the device has a standard IP address as with any host and can communicate with any other android host over TCP/IP (assuming it knows the participating device's IP? device is connected over bluetooth - how are devices identified in this case? device is connected over mobile operator's network - this is the one I'm interested in and confused by - is there anyway for two or more devices to discover each other and communicate via the mobile operator's network? How does a device communicate with a backend server in this scenario? In other words, how do apps and devices communicate when not connected to a WiFi network?
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 have developed a sports game which is single player. Now I want to have one more game mode which is multiplayer.
My question is how can i do device to device connection in android using sets of api which can be :
1.Bluetooth - whose APIs are not currently available.
2.gtalkservice - removed from sdk1.0 3.wifi - I dont knw how to connect 2 devices using wifi apis . I have asked about wifi because we have developed a game on iphone which used wifi connection for multiplayer stuff.
Or is there any other apis which can be used for implementation of multiplayer in game ?
How do I map the device Y axis to the screen Y axis?I can't figure this out.I'm the developer of Tricorder, and I'm trying to make it so that the accelerometer and magnetometer indicators I draw always point in the right direction.On the G1 phone with the slider closed, all is well.But when I open the slider, I end up showing that gravity is pulling me to the left (if the phone is held with the display vertical).So, I know that the device, and hence sensor, Y axis is always in the direction of the earpiece; and the screen Y axis changes when I open the slider.And I know that I can use remapCoordinateSystem() to change the device axes to match the screen axes.But where do I find out what the device's orientation is?In other words, how do I compute the correct values for the X and Y parameters to remapCoordinateSystem()?
Configuration.orientation seems quite useless.Suppose it is set to LANDSCAPE.What does this mean?Does it mean a device which is "naturally" portrait (i.e. the sensor Y axis points to the narrow end), and which has been turned into landscape mode?If so, which way was it turned?Or does it mean a device which is naturally landscape?In other words, LANDSCAPE could mean that the screen axis is off from the sensor axis by +90, 0, OR -90 degrees.Not much help.So how do I do this?Obviously I want my app to work on all devices, not just the G1 phone.
I have a standalone GPS enabled data recorder in my car that can function as either a USB host or device. (Its a class 0x00h USB device). I currently connect to it via a WM 6.5 app running on my Palm Treo 750. I would like to port my WM 6.5 app to an Android phone. (I don't have a specific Android phone in mind, I would like it to be as generic as possible).Replicating the GUI is not that difficult, but I am having trouble getting started on the USB communication. I'd appreciate it if someone could point me towards an example, or the appropriate tutorial.
I'm seeing that some users are downloading data via my application and their connection is dropped because the WiFi is going to sleep. Could I somehow take control over WiFi to keep it alive and once I'm done I return it to it's default state?