码迷,mamicode.com
首页 > 其他好文 > 详细

Dos烧录脚本

时间:2018-01-26 22:54:09      阅读:343      评论:0      收藏:0      [点我收藏+]

标签:备忘   wait   disk   路径   load   boot.img   loader   span   mdi   

 1 @echo off
 2 
 3 
 4 
 5 @set flashpath=Z:\msm8909\out\target\product\msm8909 6 @set boot_image=%flashpath%boot.img
 7 @set mbn_image=%flashpath%emmc_appsboot.mbn
 8 @set system_image=%flashpath%system.img
 9 @set persist_image=%flashpath%persist.img
10 @set ramdisk_image=%flashpath%ramdisk.img
11 @set recover_image=%flashpath%recovery.img
12 @set cache_image=%flashpath%cache.img
13 
14 
15 @echo 1、烧录boot.img
16 @echo 2、烧录aboot.img
17 @echo 3、烧录persist.img
18 @echo 4、烧录ramdisk.img
19 @echo 5、烧录recovery.img
20 @echo 6、烧录system.img
21 @echo 7、烧录cache.img
22 @echo 8、烧录所有镜像
23 
24 @set /p option=请先设置路径后,再输入要烧录的选项:
25 
26 
27 adb wait-for-device
28 adb reboot-bootloader
29 
30 
31 
32 if "%option%" == "1" (
33 @echo 烧录boot.img........
34 fastboot flash boot %boot_image%
35 )
36 
37 if "%option%" == "2" (
38 @echo 烧录aboot.img........
39 fastboot flash aboot %mbn_image%
40 )
41 
42 if "%option%" == "3" (
43 @echo 烧录persist.img..........
44 fastboot flash persist %persist_image%
45 )
46 
47 if "%option%" == "4" (
48 @echo 烧录ramdisk.img..........
49 fastboot flash ramdisk %ramdisk_image%
50 )
51 
52 if "%option%" == "5" (
53 @echo 烧录recovery.img...........
54 fastboot flash recovery %recover_image%
55 )
56 
57 if "%option%" == "6" (
58 @echo 烧录system.img........
59 fastboot flash system %system_image%
60 )
61 
62 if "%option%" == "7" (
63 @echo 烧录cache.img...........
64 fastboot flash cache %cache_image%
65 )
66 
67 if "%option%" == "8" (
68 @echo 烧录所有镜像.............
69 fastboot flash boot %boot_image%
70 fastboot flash aboot %mbn_image%
71 fastboot flash persist %persist_image%
72 fastboot flash ramdisk %ramdisk_image%
73 fastboot flash recovery %recover_image%
74 fastboot flash system %system_image%
75 fastboot flash cache %cache_image%
76 )
77 
78 
79 
80 fastboot reboot
81 adb wait-for-device
82 adb root
83 adb wait-for-device
84 
85 
86 @ping -n 5 127.0.0.1>nul
87 adb shell dmesg > kmesg.log
88 @echo kernel log已经导出.....
89 
90 
91 
92 @echo [烧录成功,暂停5秒自动关闭]
93 @ping -n 5 127.0.0.1>nul

dos烧录镜像脚本,以防备忘;

Dos烧录脚本

标签:备忘   wait   disk   路径   load   boot.img   loader   span   mdi   

原文地址:https://www.cnblogs.com/linhaostudy/p/8361527.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!