Giter Site home page Giter Site logo

mediatek_flash_tool's Introduction

MediaTek Flash Tool

Library and command line tool for interacting with the MediaTek bootloader, for dumping and flashing firmware.

Dependencies

  • Argp (included with glibc and gnulib) or argp-standalone
  • libusb >= 1.0.16

Limitations

  • Only tested on MT6580, with Download Agent from SP Flash Tool
  • Only supports EMMC devices

Features

  • Supports auto-detecting device (requires hotplug capability in libusb)
  • Supports sending Download Agent to Preloader
  • Supports multiple dumping or flashing operations
  • Supports arbitrary address and length without scatter file
  • Supports rebooting the device after operations are completed
  • Enables USB 2.0 mode in Download Agent

Examples

Dumping the GPT, using the appropriate Download Agent from MTK_AllInOne_DA.bin.

flash_tool -d MTK_AllInOne_DA.bin -l 17408 -D GPT.bin

Assume the boot partition starts at 0x1d80000, with a length of 0x1000000.

Dumping the boot partition to boot.bak, flashing boot.img to the boot partition, and rebooting.

flash_tool -d MTK_AllInOne_DA.bin -R -a 0x1d80000 -l 0x1000000 -D boot.bak -F boot.img

Dumping the boot partition to boot.bak, patching it, flashing it back to the boot partition, and rebooting.

flash_tool -d MTK_AllInOne_DA.bin -a 0x1d80000 -l 0x1000000 -D boot.bak
./patch.sh boot.bak boot.img
flash_tool -2 -R -a 0x1d80000 -l 0x1000000 -F boot.img

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.