[TUTORIAL]How to setup SP_Flash_Tool_Linux (MTK/MediaTek Soc)
DISCLAIMER: It is always risky to flash your mobile device. I do not and will not take any responsibility for bootloops and bricks.
Please check carefully that the ROM or recovery.img you want to flash is suitable for your specific device and for the sp_flash_tool. The firmware directory should neither contain meta-inf nor system folder, but something_with_a_scatter.txt and a system.img
Backup your phone before flashing!
Your phone's battery should be at least half charged (50 percent) before you start this.
I successfully ran these steps on my UMI Hammer with Linux Ubuntu 14.04. I do not have other devices or Linux derivates and do not plan to buy/install any.
CREDITS and a zillion thanks to Sergio Rivero for his excellent tutorial on mibqyyo.com!!!!
Also many thanks to N2K1 for giving me some more background information!
So here we go:
Step 1:
If you haven't done so before, install the Linux generic usb-drivers package:
sudo apt-get install libusb-dev
Download https://androidmtk.com/smart-phone-flash-tool
I recommend version 5.1604 or newer.
Step 2:
Extract the downloaded file -> graphic file manager (e.g. Nautilus): double-click and extract. Terminal:
unzip path_to_file
(from now on: please adapt paths to your own settings)
Move the new folder „sp_flash_tool“ to a directory of your choice.
mv /home/username/Downloads/sp_flash_tool /home/username/...
Step 3:
Change into the newly created directory:
cd /sp_flash_tool
We make one file executable by typing:
chmod +x flash_tool
In order to avoid running the flash_tool as root user, you need to add a standard user to the usergroup "dialout" (thanks to @egalus for this bit!)
sudo adduser username dialout
For Arch Linux:
gpasswd -a username uucp
and activate the membership immediately
newgrp - dialout
(Arch Linux):
newgrp - uucp
Step 4:
Now you can open the tool:
./flash_tool
or double-click on the flash_tool icon.
You can try at this stage if the flash tool connects to your phone:
In the user interface, choose tab „Download“. Hit "scatter-loading", navigate to a directory with a valid firmware for your device and choose the scatter-file.
For testing purposes uncheck "name" and check one of the smaller files in the list below (for example "logo")
Switch off your device. Hit the "Download" button in SP_Flash_Tool and connect your phone to the computer. Some devices require you to take off the battery for about 10 seconds, with others you need to press Vol+ or Vol- while plugging the cable into the phone. Please look up device-specific threads and try out different options.
If nothing happens at all, open a second terminal, run
dmesg | grep usb
and look out for a MediaTek entry. If there is none → did you install libusb-dev (Step 1?)
If the answer is yes, you might need to create a persistent udev rule for the MTK Preloader:
sudo gedit /etc/udev/rules.d/80-persistent-usb.rules
Add the following line to the file:
SUBSYSTEM=="usb", ACTION=="add", ATTR{idVendor}=="0e8d", ATTR{idProduct}=="*"
Save the file and exit.
Reload the usb-rules:
sudo service udev restart
Disconnect the usb data cable from the computer and the smartphone. Close the flash tool. Switch on your phone (fastboot mode will do). Repeat the first paragraph of Step 4.
If the tool connects, within a few seconds a red progress bar will appear. Unfortunately, in my case an error message came along with it:
S_BROM_CMD_JUMP_DA_FAIL (2035)
There is a connection, but also one more obstacle to overcome...
Step 5:
Now we come to the interesting part, which cost me 2 weeks of (futile) research and frustration. Finally I found Sergio Riveros tutorial on mibqyyo. Thanks to him again and again and again for this priceless piece of information
The “modemmanager” package integrated by default within Linux Ubuntu 14.04 and later is not compatible with the MTK Flash Tool for Linux
To put it in different words: The modem manager controls port /dev/ttyACM0 and disables the Flash Tool. So we blacklist it for the two MTK vendor IDs the flash tool uses:
sudo gedit /etc/udev/rules.d/20-mm-blacklist-mtk.rules
You insert these two lines:
ATTRS{idVendor}=="0e8d", ENV{ID_MM_DEVICE_IGNORE}="1"
ATTRS{idVendor}=="6000", ENV{ID_MM_DEVICE_IGNORE}="1"
Save the file, exit and restart udev:
sudo service udev restart
Switch your phone on (fastboot mode will suffice) and off again.
Step 6:
./flash_tool
or double-click on the flash_tool icon.
Now everything should run smoothly. In case you encounter
BROM ERROR : S_SECURITY_SF_CODE_FORMAT_FORBIDDEN (6012) , MSP ERROE CODE : 0x00
change the download agent to MTK_AllInOne_DA.bin (screenshot #4)
There are plenty of tutorials on the web for the further steps.
Happy flashing! When a green circle with a white checkmark appears, you are done. You can close the flash tool and disconnect your phone. Remove the battery for about 10 seconds and reinsert it. For a clean start with a new ROM boot into recovery and wipe data/factory reset.
[TUTORIAL]How to setup SP_Flash_Tool_Linux (MTK/MediaTek Soc)的更多相关文章
- 《RabbitMQ Tutorial》第 1 章 简介
本文来自英文官网,其示例代码采用了 .NET C# 语言. <RabbitMQ Tutorial>第 1 章 简介(Introduction) RabbitMQ is a message ...
- 《RabbitMQ Tutorial》译文 第 1 章 简介
原文来自 RabbitMQ 英文官网的教程(1.Introduction),其示例代码采用了 .NET C# 语言. RabbitMQ is a message broker: it accepts ...
- arm-linux下qt + opencv开发环境的搭建(Altera DE1 Soc)
arm-linux-gnueabihf-gcc下载 qt下载 arm-linux下qt + opencv开发环境的搭建(Altera DE1 Soc) Ubuntu 16.04 安装QT arm嵌入式 ...
- 【原】Configuring Oracle Data Guard In Physical Standby Database
作者:david_zhang@sh [转载时请以超链接形式标明文章] http://www.cnblogs.com/david-zhang-index/p/5042640.html参照文档:https ...
- Gazebo機器人仿真學習探索筆記(七)连接ROS
中文稍后补充,先上官方原版教程.ROS Kinetic 搭配 Gazebo 7 附件----官方教程 Tutorial: ROS integration overview As of Gazebo 1 ...
- php实现查询上传文件进度
参考:http://www.ultramegatech.com/2010/10/create-an-upload-progress-bar-with-php-and-jquery/ 11OCT/108 ...
- Learn golang: Top 30 Go Tutorials for Programmers Of All Levels
https://stackify.com/learn-go-tutorials/ What is Go Programming Language? Go, developed by Google in ...
- 服务器搭建私人Git
环境是CentOS 7.4 64位 主要参考:在服务器上搭建 Git 0. 预备 安装git yum install git 1. 开发者-生成个人SSH公钥 p.s. 书中的4.3节是[生成个人的S ...
- NS3 MyApp Class Reference
官方文档:MyApp 可以在下面的几个例子找到: examples/tutorial/fifth.cc examples/tutorial/seventh.cc examples/tutorial/s ...
随机推荐
- Scala的符号入门
Spark是由Scala编写的.Spark作为一款十分易用高效的大数据框架使用越来越广泛,Scala也随之有更多的人去学习. 语言相通,相信有python.java基础的程序员学习Scala并没有太大 ...
- Python 爬虫 (三)
#对第一章的百度翻译封装的函数进行更新 1 from urllib import request, parse from urllib.error import HTTPError, URLError ...
- centos配置NTP服务器
时间服务器: NTP(Network Time Protocol,网络时间协议)是用来使用网络中的各个计算机时间同步的一种协议,NTP服务器就是利用NTP协议提供时间同步服务的. 一.环境准备: 1. ...
- 使用bison和yacc制作脚本语言(3)
我们现在已经可以写好文法了,下一步我们打算开始正式创建工程了 在工程目录下,我们创建如下文件夹 ./include ./memory ./ms include文件夹下我们将放头文件 memory是内存 ...
- C++编译错误杂记
目录 2018年12月23日 error: no matching function for call to ××× 2018年12月10日 error: expected ')' before '* ...
- #include stdio.h(B)
#include <stdio.h> int main() { //***********一.循环语句*************** //什么叫做循环: //重复的做某件事情,重复的执行一 ...
- C# 调用腾讯云接口获取视频基本信息
做项目需要上传视频,获取时长,上传教程很多,获取信息很少,官方只有一条请求地址. 找了好久,都没有说这个请求地址怎么用.最后发现需要调用腾讯云SDK 官方地址:https://github.com/Q ...
- JetBrains Makes its Products Free for Students(JetBrains 对学生免费了)
只要你有大学有些 后缀是 .edu的 如:@buaa.edu.cn,用你的邮箱注册,就可以免费试用 JetBrains了 下面是详细注册步骤: Hello everyone, If you’re o ...
- 优步UBER司机全国各地奖励政策汇总 (2月22日-2月28日)
滴快车单单2.5倍,注册地址:http://www.udache.com/ 如何注册Uber司机(全国版最新最详细注册流程)/月入2万/不用抢单:http://www.cnblogs.com/mfry ...
- TW实习日记:第31-32天
不知不觉的,实习的净工作天数,已经都超过一个月了.因为对工作内容不是很满意,所以打算月底离职,也不知道是公司太缺人还是我真的能干活,领导竟然三番两次找我让我再考虑...明天又要找我了,哎...随机应变 ...