Get a Complete Set of Logs with Andy Log

The importance of proper logging is undeniable. No, we’re not talking about lumberjack work. … more

Try Some Android Lollipop Applications on Your Device

Android 5.0 Lollipop has been officially announced and lucky users of Google Nexus 5 … more

AutoCon Manages Your Connections to Perserve Battery Life

As we’ve talked about in the past, battery life is still somewhat of a sore … more

How to Unlock and Root a Nexus Device – XDA TV

It is official–Google has released the Nexus 6 and the Nexus 9. The Nexus family … more
Post Reply

[TOOLS][ADB][Windows]Push files to device through ADB*now include deodex tools*

OP suwandiapr

10th March 2012, 05:08 AM   |  #1  
OP Senior Member
Flag Semarang
Thanks Meter: 176
 
171 posts
Join Date:Joined: Jan 2012
Donate to Me
More
See my previous post before in post#2
This is a simple batch file using ADB..
With this you can use ADB to manage your file or APK , Backup, Push Your File to device, or pull file from device..
ADB Work on Stand by Mode (Home Screen) or in Recovery Mode, just set it up..
Extract ADBTOOLSv1.0.1.zip and you will find :
Quote:

command.bat : Windows Batch Command
_BACKUP_OUT : folder where your backup process done and made

_FLASHING_OUT:
folder for flashing your :
kernel (place your boot.img here)
recovery (place your recovery.img here),
modem (place your modem.bin here)--only for gt p7300

_MODDING_FILE: Folder where your file were created by PULL process
Folder where file for PUSH process should be here


_BATCH_INSTALL : place your APK here for batch install

tools: ADB.exe and busybox binary

success_APK : A folder created for All apk from _BATCH_INSTALL move here after instalation.

Notes:
ADB can access all file from device from CWM Recovery, especially CWMR 5.5.0.4
ALL you need to do is:
From Recovery menu, you need to mount /data and /system for ADB working..
THEN, From Command Prompt set ADB Mode to "recovery".(This Batch File set ADB mode to "Home Screen" by default)
So when you use ADB from Online device ( I mean a stand by device).. you dont need to change ADB Mode..
After you set up, you can use ADB as you like..


Code:
  =============================================================================
  :::: ADB TOOLS FOR GT P7300 and P7310 by suwandiapr
  -----------------------------------------------------------------------------
  |[*] Before use read this:                                                            
  |    --make sure you have installed adb drivers for your device             
  |    --enable "USB DEBUGGING"                                               
  |         from (Menu\Settings\Applications\Development)                   
  |    --enable "UNKNOWN SOURCES"                                             
  |         from (Menu\Settings\Applications)                                
  |    --increase screen timeout to 10 minutes                                
  |    --connect USB cable to PHONE and then connect to PC                   
  |    --MAKE SURE YOU HAVE A ROOTED DEVICE AND BUSYBOX                       
  |    --Place the right file in the right folder                            
  |    --Some feature like Flashing need more tester..so please be aware      
  |    --If you use adb recovery feature, set ADB Mode to recovery            
  |          mount /data and /system from your device recovery               
  |    --If you use adb from homescreen, set ADB Mode to HomeScreen          
  |    --All you Do is your own Risk, use with carefull                       
  -----------------------------------------------------------------------------
     ****Turn on the screen and allow superuser permission when asked!****

  _____________________________________________________________________________
  | Current MODDING FILE: NONE  | ADB MODE :HomeScreen | sdcard path: /sdcard/|
  =============================================================================  
  :::: ADB PULL ::::
  =============================================================================
  0   Pulling file from /data ( see result in _MODDING_FILE)
  1   Pulling file from /system partition ( see result in _MODDING_FILE)
  2   Pulling file from SDcard ( see result in _MODDING_FILE)
  3   Backup recovery ( see result in _BACKUP_OUT)
  4   Backup Kernel ( see result in _BACKUP_OUT)
  5   Backup modem (for P7300 only-see result in _BACKUP_OUT)
  6   Backup /system  (tar format-see result in _BACKUP_OUT)
  7   Backup /efs  (tar and .img format-see result in _BACKUP_OUT)
  8   Backup APK from /data/app (tar format-see result in _BACKUP_OUT)
  =============================================================================
  :::: ADB PUSH ::::
  =============================================================================
  9    Pushing file to /data ( from _MODDING_FILE to device)
  10   Pushing file to /system ( from _MODDING_FILE to device)
  11   Flashing recovery ( from _FLASHING_OUT to device)
  12   Flashing Kernel ( from _FLASHING_OUT to device)
  13   Flashing modem for GT P7300 ( from _FLASHING_OUT to device)
  =============================================================================
  :::: Setting ::::
  =============================================================================
  14   Set current working File ( for PUSH and PULL )
  15   Install busybox on device (need root) 
  16   Set ADB mode (if you on recovery mode)
  17   Install apk ( from _MODDING_FILE to device)
  18   Install batch apk ( from _BATCH_INSTALL to device)
  =============================================================================
  :::: Reboot Menu ::::
  =============================================================================
  19   Reboot System
  20   Boot Into Recovery
  21   Reboot Bootloader
  22   Quit
Attached Files
File Type: rar FLASHER.rar - [Click for QR Code] (507.8 KB, 1451 views)
File Type: zip ADBTOOLSv1.0.1.zip - [Click for QR Code] (850.1 KB, 6549 views)
File Type: zip convertEXT4.zip - [Click for QR Code] (4.78 MB, 999 views)
File Type: rar ADBTOOLv1.2.rar - [Click for QR Code] (6.28 MB, 3162 views)
File Type: zip dex_editor.zip - [Click for QR Code] (1,015.4 KB, 393 views)
File Type: zip adbtoolsV1.3.zip - [Click for QR Code] (5.36 MB, 1569 views)
Last edited by suwandiapr; 11th February 2013 at 08:30 PM.
The Following 10 Users Say Thank You to suwandiapr For This Useful Post: [ View ]
10th March 2012, 07:18 AM   |  #2  
OP Senior Member
Flag Semarang
Thanks Meter: 176
 
171 posts
Join Date:Joined: Jan 2012
Donate to Me
More
My previous post
inspiration from congox case
when you got a problem with bootlop and you forget make a nandroid backup

  • only have file from other ROM with flashable.zip and need to push the file from your computer to device
  • you have a recovery support with mount /system and mount /data (tested on CWM 5.5.0.4 and overcome CWM 5.1.2.6) and you can enter this menu while bootloop happen..



STEP 1 : MANUAL

  • Connect your device with computer
  • From device, Go to recovery - mounts and storage - mount /system and mount /data
  • From your computer go to adb terminal and type this
    Code:
    adb shell "ls /data/media/"
  • If you can see list of file from your device sdcard, so you make adb work for your device ..
  • Place your zip file on your path, says on C://backup.zip and you want to copy the file to /sdcard/download/ and type this code
    Code:
    adb push backup.zip /data/media/download/.
  • wait for copying progress done..
  • After you done with moving file to device sdcard, check content of your sdcard with this code
    Code:
    adb shell "ls /data/media/download/"
  • When you found your file from list, you can flash backup.zip from recovery


STEP 2 : WINDOWS BATCH FILE
I made a simple Batch File for windows (sorry i dont have MAC or LINUX distro) , this file will make a folder with name "emergency" in SDCARD and with your files inside that.

  1. Extract the FLASHER.rar somewhere on your Local folder,example: on your " Desktop" Folder
  2. in folder "FLASHER" you will find runme.bat and folder "files"
  3. Rename your file ((flashable.zip files you want to send through ADB) to "backup.zip" and then Put your file into this path /FLASHER/files/myfiles/ (just replace the existing "backup.zip" with files from yours)
  4. Connect your tab with Computer
  5. Reboot into Recovery Menu from your device
  6. From menu Mounts and Storage choose mount /system and /data
  7. From your Computer go To Folder flasher and klik runme.bat
  8. Follow the instruction on window untill copying process done and device reboot to recovery again (copying process will take a minutes depend on your file size)
  9. Now you can flash a emergency ROM from recovery


Window instruction
Code:
 -----------------------------------------------------------------------------
	          ADB EMERGENCY COPYING TOOL for TAB 8,9
                    created by SUWANDIAPR
 -----------------------------------------------------------------------------
[*] This script will:
      (1) COPY YOUR FILE FROM COMPUTER TO SDCARD/emergency/*
      (2) CHECKING YOUR CONNECTED DEVICE DIRECTORY
[*] Before u begin:   
      (1) make sure u have installed adb drivers for ur device
      (2) make sure u have installed CWM 5.5.0.4 ON YOUR DEVICE
      (3) connect USB cable to PHONE and then connect to PC
      (4) Rename your Flashable .zip file with "backup.zip"
          and place inside "myfiles" folder on your Computer
      (5) from Recovery Menu, Choose "Mounts and storage" then
                    -mount /system and -mount /data
      (6) CONNECT YOUR TAB WITH PC WHILE ON RECOVERY MENU  
 ---------------------------------------------------------------  
CONFIRM ALL ABOVE
Sorry for my Bad english, if there is somebody want to correct every words i use , im very welcome and will change with the proper words and sentence..

Hope this help someone..
Last edited by suwandiapr; 27th April 2012 at 09:31 PM.
11th March 2012, 12:12 AM   |  #3  
Member
Thanks Meter: 17
 
91 posts
Join Date:Joined: Oct 2010
Nice guide, thanks!!
6th April 2012, 12:08 PM   |  #4  
nail16's Avatar
Senior Member
Flag Mumbai
Thanks Meter: 294
 
768 posts
Join Date:Joined: Nov 2011
More
I needed some help with mounting the system using adb through a batch file.

I use this command
adb -d shell mount -o remount rw /system

But the mounting fails (I have a rooted phone )
pleas help me I know this is off topic
6th April 2012, 12:40 PM   |  #5  
Senior Member
Thanks Meter: 332
 
118 posts
Join Date:Joined: Mar 2011
2 possible reasons for this command to fail:

- /default.prop (on the phone) contains the following line: "ro.secure=1". Then you need another boot.img (in fact just a modified ramdisk). look for "unpack-bootimg.pl" or "unpackbootimage" you may find a guide how to do this manually (not too easy). A rooted kernel would also do the trick.
you can check your default prob with this command "adb shell cat /default.prop".

- in some cases mount requires more parameters. try "adb shell mount" and look for the line containing "/system". In front of system is the "device-name". in my case the mount command would look like this:

mount -o remount,rw /block/dev/mmcblk0p24 /system


hope this helps and sorry for answering off-topic questions....
Last edited by glitschi667; 6th April 2012 at 12:43 PM.
The Following User Says Thank You to glitschi667 For This Useful Post: [ View ]
6th April 2012, 02:44 PM   |  #6  
OP Senior Member
Flag Semarang
Thanks Meter: 176
 
171 posts
Join Date:Joined: Jan 2012
Donate to Me
More
Quote:
Originally Posted by nail16

I needed some help with mounting the system using adb through a batch file.

I use this command
adb -d shell mount -o remount rw /system

But the mounting fails (I have a rooted phone )
pleas help me I know this is off topic

you can use busybox and call the binary from the shell
i assume that your device in normal mode ( in home screen)..
here some example..
Code:
su
adb push busybox /tmp/.
adb shell "chmod 755 /tmp/busybox"
adb shell "tmp/busybox mount -o remount,rw /system"
after you type "su" superuser will prompt a request, choose "allow".


Quote:
Originally Posted by glitschi667

2 possible reasons for this command to fail:

- /default.prop (on the phone) contains the following line: "ro.secure=1". Then you need another boot.img (in fact just a modified ramdisk). look for "unpack-bootimg.pl" or "unpackbootimage" you may find a guide how to do this manually (not too easy). A rooted kernel would also do the trick.
you can check your default prob with this command "adb shell cat /default.prop".

- in some cases mount requires more parameters. try "adb shell mount" and look for the line containing "/system". In front of system is the "device-name". in my case the mount command would look like this:

mount -o remount,rw /block/dev/mmcblk0p24 /system


hope this helps and sorry for answering off-topic questions....

yes you right glistchi, samsung lock adb root on new firmware on my SG- Note..
And make me flash an older firmware for rooting..
27th April 2012, 09:36 PM   |  #7  
OP Senior Member
Flag Semarang
Thanks Meter: 176
 
171 posts
Join Date:Joined: Jan 2012
Donate to Me
More
Talking
new update
15th June 2012, 03:41 PM   |  #8  
Member
Thanks Meter: 10
 
79 posts
Join Date:Joined: May 2010
More
Never mind, got it to work
Last edited by imreezm; 15th June 2012 at 03:48 PM.
19th October 2012, 08:15 AM   |  #9  
fariz_kd's Avatar
Member
Thanks Meter: 1
 
30 posts
Join Date:Joined: Feb 2011
i want to push same file in data system (/data/data) but my tab is not root. can i??
19th October 2012, 08:51 AM   |  #10  
OP Senior Member
Flag Semarang
Thanks Meter: 176
 
171 posts
Join Date:Joined: Jan 2012
Donate to Me
More
if from cwm recovery, yes you can.. if from stand by mode (home screen) the answer is no... you need root to make it happen..

Post Reply Subscribe to Thread
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes