diff --git a/README.md b/README.md
index 337ce03..fc10cf9 100644
--- a/README.md
+++ b/README.md
@@ -118,7 +118,7 @@ sudo reboot
## Usage
### Using MTKTools via the graphical user interface:
-For the 'basics' you can use the GUI interface. This supports dumping partitions for now. Run the following command:
+For the 'basics' you can use the GUI interface. This supports dumping partitions or the full flash for now. Run the following command:
```
python mtk_gui
```
diff --git a/mtk_gui b/mtk_gui
index 3cbaca1..fd76c2b 100755
--- a/mtk_gui
+++ b/mtk_gui
@@ -62,10 +62,13 @@ def getDevInfo(self, parameters):
mtkClass = devhandler.mtkClass
da_handler = devhandler.da_handler
- if mtkClass.port.cdc.connect() == False:
- mtkClass.preloader.init()
- else:
- phoneInfo['cdcInit'] = True;
+ try:
+ if mtkClass.port.cdc.connect() == False:
+ mtkClass.preloader.init()
+ else:
+ phoneInfo['cdcInit'] = True
+ except:
+ phoneInfo['cantConnect'] = True
phoneInfo['chipset'] = str(mtkClass.config.chipconfig.name) + \
" (" + str(mtkClass.config.chipconfig.description) + ")"
self.sendUpdateSignal.emit()
@@ -81,6 +84,9 @@ def getDevInfo(self, parameters):
else:
phoneInfo['bootMode'] = "Preloader mode"
self.sendUpdateSignal.emit()
+ else:
+ phoneInfo['cantConnect'] = True
+ self.sendUpdateSignal.emit()
# try:
# print(mtkClass.daloader.get_partition_data(parttype="user"))
# except Exception:
@@ -96,7 +102,10 @@ def sendToLog(info):
def updateGui():
global phoneInfo
- mainwindow.phoneInfoTextbox.setText("Phone detected:\n" + phoneInfo['chipset'] + "\n" + phoneInfo['bootMode'])
+ if (phoneInfo['cdcInit'] and phoneInfo['bootMode'] == "" ):
+ mainwindow.phoneInfoTextbox.setText("Phone detected:\nReading model info...")
+ else:
+ mainwindow.phoneInfoTextbox.setText("Phone detected:\n" + phoneInfo['chipset'] + "\n" + phoneInfo['bootMode'])
mainwindow.status.setText("Device detected, please wait.\nThis can take a while...")
if phoneInfo['daInit']:
mainwindow.status.setText("Device connected :)")
@@ -106,7 +115,7 @@ def updateGui():
spinnerAnim.stop()
mainwindow.spinner_pic.setHidden(True)
else:
- if not phoneInfo['cdcInit']:
+ if 'cantConnect' in phoneInfo:
mainwindow.status.setText("Error initialising. Did you install the drivers?")
spinnerAnim.start()
mainwindow.spinner_pic.setHidden(False)
diff --git a/mtkclient/gui/main_gui.py b/mtkclient/gui/main_gui.py
index 6dfe8ab..4ac8ab2 100644
--- a/mtkclient/gui/main_gui.py
+++ b/mtkclient/gui/main_gui.py
@@ -198,7 +198,6 @@ class Ui_MainWindow(object):
self.menubar.addAction(self.toolsFlashMenu.menuAction())
self.readFlashMenu.addAction(self.actionRead_partition_s)
self.readFlashMenu.addAction(self.actionRead_full_flash)
- self.readFlashMenu.addAction(self.actionRead_offset)
self.writeFlashMenu.addAction(self.actionWrite_partition_s)
self.writeFlashMenu.addAction(self.actionWrite_full_flash)
self.writeFlashMenu.addAction(self.actionWrite_at_offset)
diff --git a/mtkclient/gui/main_gui.ui b/mtkclient/gui/main_gui.ui
index 6310eac..8e99775 100755
--- a/mtkclient/gui/main_gui.ui
+++ b/mtkclient/gui/main_gui.ui
@@ -413,7 +413,6 @@
-