hello
i have nokia 7 plus
i am try in some adb commant to check phone bootloader unlock
but i unfortunately run this two both comand
// Emulate device
adb shell wm size 2048x1536
adb shell wm density 288
// And reset to default
adb shell wm size reset
adb shell wm density reset
when i am try to rest it will be done but when i will reboot device again screen size & density will change and it become smaller (only half screen will be useable )
so plz help me to out this problem
every time i need to run reset command from pc then it will go to normal state...
thanx
Related
Hi,
With my 2 previous android devices I never had problems using start/stop shell command.
I use them when pushing a new apk in /system/app or /system/framework, for example:
- adb shell stop
- remount /system rw
- push SystemUI.apk
- adb shell sync
- remount /system ro
- adb shell start
This sequence was for me a secure way to test a new apk version without having to make a full reboot and/or flash a .zip file. It's also easy to have issues copying a new system apk while the system is running.
Whith my xperia SP I experienced a nice system hang:
- First time I used this sequence my phone was not with the lockscreen ON (desktop was visible) and everything restarted well
- The second time my phone was sleeping (lockscreen ON and black screen). Then, after the "start" command I saw with adb logcat that everything was running again but ... the screen stay black, impossible to wake-up the phone. Ok, so I made reboot and ... total system hang with the red led ON (battery charge) even without the usb cable connected. Then, RESET button and the phone boot normally.
Any opinion on that ? What do you devs do to test a new version of a system apk ?
Thanks
So, after owning my beautiful Moto X for 1 month, I found that the screen is not nearly as shatter resistant as my old iPhone 4S. After managing to completely shatter it, I called Motorola up for a replacement (which for a customized Pure cost $125) and it was on its way, but before that I needed to get my old data off. Luckily I have unlocked my bootloader and rooted my phone in advance, but i had turned off USB debugging and had a passcode lock. All of the guides for making a full backup assume that you have screen access. After messing around for a few days, I finally managed to make a full backup of my phone. I thought I'd put together this guide for anyone else who has the same issue.
Assumptions
Your bootloader is unlocked and phone rooted (do not try to unlock it now or it will wipe the phone)
Your phone is not encrypted (there's still a way around this which I'll cover but I did not have to use)
You have ADB/fastboot set up on your computer (and have tested it at least once)
Required files/guides
CWM recovery file - http://motoxroot.com/cwmtwrp-recovery-for-moto-x/
Lock Screen removal guide - http://forum.xda-developers.com/showthread.php?t=1409304
SQLite DB editor (I'm on Windows) - http://sqliteadmin.orbmu2k.de/
Androidscrencast - https://code.google.com/p/androidscreencast/
ADB keystroke events - http://thecodeartist.blogspot.com/2011/03/simulating-keyevents-on-android-device.html
Steps
The first thing I did was download the customer CWM image for the 2014 Moto X which can be found here:
Code:
http://motoxroot.com/cwmtwrp-recovery-for-moto-x/
Next I went rebooted the phone into bootloader mode by holding "Volume Down + Power" for about 15 seconds. I could not see images on the screen but I could tell when it lit up.
Note: If you have an encrypted phone, you can use an OTG cable and a standard USB keyboard to type in the password blind. I used something similar for the PIN code, however this guide does not actually need to worry about that
Test that you have fasboot access by running
Code:
fastboot devices
You should see your device listed
Boot the CWM recovery image (you do not have to flash it which is nice)
Code:
fastboot boot XT1095recovery.img
Wait a few seconds and verify that you can now access your phone via ADB
Code:
adb devices -l
If this works, you now have a shell to be able to do the next part which is removing the passcode and enabling USB Debugging I followed the guide at http://forum.xda-developers.com/showthread.php?t=1409304 to do remove the lock screen
Mount the data partition of your phone by running
Code:
adb shell mount data
adb shell mount system
Grab the settings DB from the phone and copy it locally (Other guides say to copy to an intermediary, but since you're using a recovery ROM the files can be directly accessed)
Code:
adb pull /data/data/com.android.providers.settings/databases/settings.db settings.db
Open the file in your SQLite editor of choice and run the following statements
Code:
UPDATE secure SET value=65536 WHERE name='lockscreen.password_type';
UPDATE secure SET value=0 WHERE name='lock_pin_autolock';
While we have the settings DB open, it's also a good time to enable ADB Debugging by running the following statements (credits to http://stackoverflow.com/questions/13326806/enable-usb-debugging-through-clockworkmod-with-adb though I had to mod some more stuff)
Code:
UPDATE global SET value=1 WHERE name='adb_enabled';
UPDATE global SET value=1 WHERE name='development_settings_enabled';
Push the file back to it's original location
Code:
adb push settings.db /data/data/com.android.providers.settings/databases/settings.db
From here, the next set of commands should be run within the shell. You can access it by running
Code:
adb shell
Remove some existing property files
Code:
rm /data/property/persist.service.adb.enable
rm /data/property/persist.sys.usb.config
Add in the ADB settings
Code:
echo "persist.service.adb.enable=1" >>/system/build.prop
echo "persist.service.debuggable=1" >>/system/build.prop
Correct the permissions for the settings.db file
Code:
chown system:system /data/data/com.android.providers.settings/databases/settings.db
chmod 660 /data/data/com.android.providers.settings/databases/settings.db
At this point, everything is ready to go and we're ready to reboot to your real install with no pin code and ADB enabled.
Reboot your phone
Code:
adb reboot
Run androidscreencast (don't worry about the keyboard/mouse instructions they don't work). Chances are the screen will be blank, press the Power button your phone and wait (it's got a *very* slow refresh rate)
Once you see your desktop, you can now run an ADB backup. I like getting everything, but this will take a while because it grabs all images, music, SD card stuff, etc.
Code:
adb backup -apk -shared -all -f backup.ab
On the screencast you'll see the prompt pop up asking you to enter a password and confirm. This was the part that took me a while and you have to do it fairly quickly otherwise it'll time out. In a separate windows run
Code:
adb shell input text <yourpassword>
adb shell input keyevent 61
adb shell input keyevent 61
adb shell input keyevent 66
At this point, you should see a full backup kicking off and running. You can run a logcat to watch the process of it. In some cases a full backup may hang if a resource has a file open, the two commands to work with this are:
Code:
adb shell logcat | grep BackupManagerService
To kill a process the backup is hanging on, enter the shell
Code:
su
ps | grep <nameOfProcess>
am force_stop <nameOfProcess> (the clean way)
kill <pid> (the dirty way)
Hope this helps! This took me a little while to figure out but now I have a full backup and my new Moto X will be here within the
week.
Okay so an ADB full backup sucks for a restore. Luckily I got a nandroid backup instead and that worked much better. There's some stuff you have to do with mapping /sdcard for it to work on the Moto X. I'll update this post soon with that information.
Thanks a lot for this! Helped me recover all my data from a Moto X with a completely broken blank screen!
This is an awesome Guide! Congrats!! I have a different situation. My Moto X 2014 is the XT1097 variant. The phone was neither rooted nor had an unlocked bootloader before the screen died. I downloaded the stock rom for my device, and flashed it with RSD Lite, since the program sees the phone connected in fastboot mode. Do you think I could use this method to reach the desktop? Also, the recovery.img in your guide is for the XT1095. Would it work for the XT1097? I know I can unlock the bootloader via fastboot, but what about rooting? Thanks in advance!!
Hi,
when setting a non-default DPI (240) several app UI are broken. The positon of UI elements are misplaced.
Anyone else experiencing the same?
DocMAX
DocMAX said:
Hi,
when setting a non-default DPI (240) several app UI are broken. The positon of UI elements are misplaced.
Anyone else experiencing the same?
DocMAX
Click to expand...
Click to collapse
i have problem when i change the DPI, the device reboot and is infinite bootanimation, i need to forze the reboot and then it show Optimizing apps ... and it boot fine, that's my problem while change the dpi. strange problem
I experience the sam that @JAppina92 but i use 280 dpi and no problem
Enviado desde mi Moto G 2014 mediante Tapatalk
japoina92 said:
i have problem when i change the DPI, the device reboot and is infinite bootanimation, i need to forze the reboot and then it show Optimizing apps ... and it boot fine, that's my problem while change the dpi. strange problem
Click to expand...
Click to collapse
Bro it's CM 13 bug softboot is broken...
We Are Titans
---------- Post added at 04:13 AM ---------- Previous post was at 04:12 AM ----------
DocMAX said:
Hi,
when setting a non-default DPI (240) several app UI are broken. The positon of UI elements are misplaced.
Anyone else experiencing the same?
DocMAX
Click to expand...
Click to collapse
You better try changing dpi with any root Explorer by editing buildprop from there. It help me when my ui elements are misplaced. Go to root > system > buildprop and edit it with text editor find lcd density and change it to 240 or whatever u want and then reboot...
We Are Titans
Reset DPI to stock
Hey all,
I change my phone (moto g xt1032) dpi via adb command. But unless o type 260 i type 560 in command.
adb shell wm density 560 && adb reboot.
The device boot ok, but now i cant enter on the main screen (see attachement) and the adb dont work anymore (phone is locked).
Someone know how to reset the phone or dpi to stock in this mode ?
Regards
Done
puiatmp said:
Hey all,
I change my phone (moto g xt1032) dpi via adb command. But unless o type 260 i type 560 in command.
adb shell wm density 560 && adb reboot.
The device boot ok, but now i cant enter on the main screen (see attachement) and the adb dont work anymore (phone is locked).
Someone know how to reset the phone or dpi to stock in this mode ?
Regards
Click to expand...
Click to collapse
Hey, i found how to resolve my problem.
https://motorola-global-portal.custhelp.com/app/answers/prod_answer_detail/a_id/99825/p/30,6720,9151
And if someone wanna change DPI withou root, do the following:
Use ADB:
adb shell wm density “INSERT_DPI” && adb reboot
ex: adb shell wm density 260 && adb reboot
If you want to reset the DPI back to its original value, run the following command in ADB:
adb shell wm size reset && adb reboot
so i was searching for some settings to change through adb and i found this which seems to (slightly) increase the max volume on my headphones, enable debug mode, then using adb on a command line :
adb shell settings put system volume_music_headphone 9
adb shell settings put system volume_music_headset 9
adb shell settings put system volume_music 12
it seems like "volume_music_headphone" and "volume_music_headset" can be set to 9 maximum, if you try to set it higher it will go back to 9, the default value is 8 so it does increase the volume a bit, not that much but still noticable
the "system volume_music" doesn't seems to have a max value, i tried 12 but i didn't try higher
those modifications are saved even if the phone is restarted! :good:
to check the values :
adb shell settings get system volume_music_headphone
etc..
to get a list of various settings:
adb shell settings list global
adb shell settings list system
adb shell settings list secure
some settings are reset to default value after reboot,
does it work with bluetooth audio ?? I cant test right now.
I have a Redmi K20 Pro, not rooted, my display screen broke and has gone all blue black.
I can access phone with adb though. But cannot access the file system from my PC.
Is there anyway I can backup my photos and files to my PC, using adb or some other command ?
I have to give phone to replace screen at service center and they factory reset phone without backing up anything.
I just need to get hold of my photos and videos.
Please help. TIA !
Try the adb pull command.
If you don't know the exact location of your data try the adb shell command to start a shell session, then you can use the ls and cd commands to browse the file system first. After exiting the shell you can use the adb pull command to download specific folders to the PC.
If only the screen is broken and the device is still working, then you can try scrcpy ( have both 32 and 64 bit version ). As long as your device is enable USB Debugging, then the device's creen will be mirrored to PC, from there u can see and do what u wanna do!