tips:android:adb

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
tips:android:adb [2015/02/26 15:42] – created scipiotips:android:adb [2018/05/23 18:28] (current) – [unbrick with FASTBOOT update] scipio
Line 1: Line 1:
 ====== Android ====== ====== Android ======
  
-===== Pull package =====+{{tag>[android]}} 
 +<code bash> 
 +apt-get install android-tools-fastboot 
 +apt-get install android-tools-adb 
 +</code>
  
 +===== network mode =====
  
 +<code bash>
 +adb -d tcpip 5555
 +adb connect <ip>
 +</code>
 +
 +====== Packages ======
 +
 +===== Install =====
 +
 +<code bash>
 +adb install <file.apk>
 +</code>
 +
 +===== Pull package =====
  
 Getting list of packages Getting list of packages
Line 19: Line 38:
 </code> </code>
  
 +===== Backup package =====
  
 +<code bash>
 +adb backup  -f appBackup.ab  com.corp.appName
 +</code>
  
 +This archive can be converted in tar with
 +<code bash>
 +dd if=appBackup.ab  bs=1 skip=24|openssl zlib -d > appBackup.tar
 +</code>
 +
 +====== Take screenshot ======
 +
 +<code bash>
 +adb shell screencap -p | perl -pe 's/\x0D\x0A/\x0A/g' > screen_name.png
 +</code>
 +
 +====== boot custom recovery ======
 +
 +Boot recovery image [[TWRP for mi4c|https://mega.nz/#!kM02hYKa!YOgKkCtRu-7wQT8JK4naRMPRExwpwKF0_vAVa4nwIqo]]
 +<code>
 +1) cancellare la cache (wipe cache) e fare il reboot
 +
 +adb reboot bootloader
 +fastboot flash recovery <recovery.img>
 +fastboot reboot
 +adb reboot recovery
 +</code>
 +
 +====== check lock ======
 +
 +in fastboot mode (Volume - and power)
 +<code bash>
 +fastboot oem device-info
 +</code>
 +
 +unlock
 +<code bash>
 +fastboot oem unlock-go
 +</code>
 +
 +
 +====== unbrick with FASTBOOT update ======
 +
 +Enable OEM unlock and USB debugging in developer options (tap 7 times on miui version in info phone)
 +
 +Download fastboot image from  http://en.miui.com/a-234.html
 +
 +Untar image and enter inside from terminal
 +<code bash>
 +chmod +x flash_all*
 +
 +sudo adb reboot edl
 +# or sudo fastboot oem edl
 +sudo fastboot devices
 +./flash_all_except_data_storage.sh
 +</code>
  • tips/android/adb.1424961774.txt.gz
  • Last modified: 2015/02/26 15:42
  • by scipio