Android fastboot 模式升级

发布时间:2013-01-01 19:54:46   来源:文档文库   
字号:

fastboot模式升级

 

 

Windows下开发:

fastboot升级模式供开发人员使用,它可以升级系统的单个组件。使用fastboot模式升级必须有“fastboot”程序和USB线。

fastbootGoogle提供的控制台程序,你可以在Google提供的Android SDK中找到这个程序。所以通过这种方式升级需要安装Google提供的Android SDK

现在假设你的SDK的路径为D:/$PATH

1 通过USB线连接PC,按下“BACK”键,启动机器。系统进入“fastboot”模式。

2 PC机命令行中进入SDK目录: D: cd $PATH cd tools 输入“fastboot devices”检查机器的链接状态,如果连接正确,运行该指令会输出: D:/android/android-sdk-windows-1.6_r1/tools>fastboot devices ? fastboot 否则不会有任何输出。

3 设置“ANDROID_PRODUCT_OUT”环境变量,该变量指定编译产生的镜像文件在PC机上的存放路径。通过指定该变量,在升级过程中我们不需要使用镜像文件的全路径。

假设镜像文件的存储路径为D:/product/,设置ANDROID_PRODUCT_OUT环境变量的命令为: set ANDROID_PRODUCT_OUT= D:/product/

4 使用”fastboot flash boot”命令更新boot.img,使用”fastboot flash system”命令更新system.img,使用”fastboot flashall”命令更新所有img文件。

通过fastboot可以更新的组件有boot.imgsystem.imgrecovery.img

对这三个文件的描述如下: boot.img, recovery.img, and system.img are used to download. boot.img is kernel + ramdisk + command line parameter + base address. So if you change kernel codes or ramdisk files, you must execute “make” command from root folder and download it. You can optionally download one of boot.img and system.img. (“recovery.img” can be optional.)

 

Linux下开发:

1.需要Fastboot程序(在编译过的Android源码中可以找到),usb线连接设备,按住home重启

2.切换成root用户执行命令(下面都用root用户操作): ./fastboot devices, 如果可以显示信息,则表示识别到了设备

3.设置升级包路径:export ANDROID_PRODUCT_OUT=/your_rom_path/

4.切换成root用户执行命令:fastboot flash boot

本文来源:https://www.2haoxitong.net/k/doc/b7cbd93deefdc8d376ee32f3.html

《Android fastboot 模式升级.doc》
将本文的Word文档下载到电脑,方便收藏和打印
推荐度:
点击下载文档

文档为doc格式