Tuesday, October 11, 2016

adb usb debug မ on ထားတဲ့ ဖုန္းမ်ားကို usb debug on ျဖစ္ေအာင္ recovery မွတဆင့္နွင့္ boot.img ျပ ု ျပင္ ၿခင္း ျဖင့္ ရေအာင္ လုပ္ နညး္ (general knowledge)

adb usb debug မ on ထားတဲ့ ဖုန္းမ်ားကို usb debug on ျဖစ္ေအာင္ recovery မွတဆင့္နွင့္ boot.img ျပ ု ျပင္ ၿခင္း ျဖင့္ ရေအာင္ လုပ္ နညး္ (general knowledge)


reboot into recovery mode 
recovery က ေန data partition ကို mount ဖို ့ 
/data/property/persist.service.adb.enable
mount ျပီး အဲ့အပိုင္း ကို ျပပါ 
echo 1 > /data/property/persist.service.adb.enable
1 ဟု ေျပာင္း
credit 
http://forum.xda-developers.com/showthread.php?t=893434
=======

boot.img မွာ usb debug enable ျဖစ္ဖို ့ ျပင္ရမည့္ေနရာ default.prop and system/build.prop
Added to default.prop and /system/build.prop
Code:
persist.service.adb.enable=1 
persist.service.debuggable=1
persist.sys.usb.config=mtp,adb
recovery က ေန mount ျပီး ျပင္ဖို့
adb shell
su
mount -o remount,rw /system
cd /
echo “persist.service.adb.enable=1” >> default.prop 
echo “persist.service.debuggable=1” >> default.prop
echo “persist.sys.usb.config=mtp,adb” >> default.prop
echo “persist.service.adb.enable=1” >> /system/build.prop 
echo “persist.service.debuggable=1” >> /system/build.prop
echo “persist.sys.usb.config=mtp,adb” >> /system/build.prop
ဒီေနရာမွာ echo က default.pro and build.prop ထဲကို value ေတြ ေပါင္းထည့္တာပါ
credit
http://forum.xda-developers.com/showthread.php?t=2335799
======

stock recovery ကို သြား
For Jellybean 4.2.1:
Boot into Recovery and mount Data partition.
Open a shell on PC and type:
adb pull /data/property/persist.sys.usb.config ~/
Repace ~/ with home directory of your OS.
Open that file in a text editor and you would possibly see mtp written there. Change it to mtp,adb.
Note that sometimes Android doesn’t understand the text file changes if the line terminator is “DOS Terminators” which Notepad would probably do on
Windows (mine is Linux so no issue here).
In that case, I would suggest not using adb pull but doing:
adb shell
echo ‘mtp,adb’ > /data/property/persist.sys.usb.config
You may verify that the echo command overwrote the file by using:
adb pull /data/property/persist.sys.usb.config ~/
and seeing the file’s content in some text editor.
Unmount Data and reboot into Android OS. USB Debugging would probably be enabled.
For Lollipop 5.0: 5.0 မွာ က်ေတာ့ DB Browser နဲ့ /data/data/com.android.providers.settings/databases/settings.db ကို ျပင္မွ ရပါတယ္
the global table မွာ value ေတြကို ေျပာင္းေပးမွ ရပါမယ္
JB 4.2.1 users can also follow this method if the previous one didn’t work for them.
Boot into Recovery and mount Data partition.
Repeat step 2 and 3 used in JB 4.2.1 method.
We need to tweak some parameters in settings.db. Type:
adb pull /data/data/com.android.providers.settings/databases/settings.db ~/

Back it up at some other location too, and open the file in an SQLITE editor. I’m running Linux and DB Browser for SQLite works well. It’s also available 
for Windows OS/OSX.
http://sqlitebrowser.org/
In the global table, change the value for:
adb_enabled to 1
development_settings_enabled to 1
Check that verifier_verify_adb_installs is set to 1 in the global table.
Check that as default, in the secure table:
adb_notify is 1
adb_port is -1
These checks in step 6 and 7 are not necessary but should be done so that troubleshooting becomes rather easy if the solution doesn’t work for you.
Save the changes in settings.db and copy it back into Android by typing:
ေျပာင္း ျပီး ျပန္ ထည့္ေသာအခါ ရိုက္ရမည္ command
adb shell 
rm /data/data/com.android.providers.settings/databases/settings.db
exit
adb push ~/settings.db /data/data/com.android.providers.settings/databases/

That delete (rm) command is not necessary since adb push should overwrite the file, but I executed it for my peace of mind.
Unmount Data and reboot into Android OS. ADB probably would be enabled.
rm ဆိုတဲ့ command ကို အထူးတလည္ရိုက္စရာမလိုပါ push သံုးလုိက္တာဟာ အစားထိုးသြားပါလိမ့္မယ္
ဒါကေတာ့ sqlite3 ကို သံုး ျပီး 5.0 ေတြမွာ usb debug enable လုပ္ဖို ့ ျပ ုျပင္သြားတဲ့ command ပါ 
Code:
adb shell
su
sqlite3 data/data/com.android.providers.settings/databases/settings.db
update global set value=1 where name=’adb_enabled’;
exit
exit


Credit >>> Su Su Tun

No comments:

Post a Comment

Mi Account Lock က်ပီး Password ေမ့ေနတ့ ဖုန္းေတြကို Account lock ျဖည္နည္းေလးပါ(ဖုန္းျဖင့္ျဖည္နည္း) က်ေနာ္ေတြ႔ၾကံဳတာေလးျပန္မ်ွေဝတာပါ မိမိဖ...