Update mtk_gui

This commit is contained in:
Bjoern Kerler 2023-07-12 13:04:04 +02:00
parent d326a3fa2e
commit 054dafacaa
10 changed files with 8 additions and 37 deletions

View file

@ -504,13 +504,15 @@ class MainWindow(QMainWindow):
self.ui.connectInfo.setHidden(True)
self.ui.partProgress.setHidden(False)
self.ui.fullProgress.setHidden(False)
self.ui.tabWidget.setHidden(False)
self.initread()
self.initkeys()
self.initunlock()
self.initerase()
self.initwrite()
self.getpartitions()
self.ui.tabWidget.setCurrentIndex(0)
self.ui.tabWidget.update()
self.ui.tabWidget.setHidden(False)
else:
if 'cantConnect' in phoneInfo:

View file

@ -22,9 +22,6 @@ class Port(metaclass=LogBase):
def __init__(self, mtk, portconfig, serialportname:str=None, loglevel=logging.INFO):
self.__logger = logsetup(self, self.__logger, loglevel, mtk.config.gui)
self.info = self.__logger.info
self.debug = self.__logger.debug
self.error = self.__logger.error
self.config = mtk.config
self.mtk = mtk
self.serialportname = None

View file

@ -32,9 +32,6 @@ class crypto_setup:
class hwcrypto(metaclass=LogBase):
def __init__(self, setup, loglevel=logging.INFO, gui: bool = False):
self.__logger = logsetup(self, self.__logger, loglevel, gui)
self.info = self.__logger.info
self.error = self.__logger.error
self.warning = self.__logger.warning
self.dxcc = dxcc(setup, loglevel, gui)
self.gcpu = GCpu(setup, loglevel, gui)
self.sej = sej(setup, loglevel)

View file

@ -1076,10 +1076,6 @@ class dxcc(metaclass=LogBase):
self.writemem = setup.writemem
self.da_payload_addr = setup.da_payload_addr
self.__logger = self.__logger
self.info = self.__logger.info
self.error = self.__logger.error
self.warning = self.__logger.warning
self.reg = dxcc_reg(setup)
def tzcc_clk(self, value):

View file

@ -195,9 +195,6 @@ def xor_data(a: bytearray, b: bytearray, length=None):
class GCpu(metaclass=LogBase):
def __init__(self, setup, loglevel=logging.INFO, gui: bool = False):
self.__logger = logsetup(self, self.__logger, loglevel, gui)
self.info = self.__logger.info
self.error = self.__logger.error
self.warning = self.__logger.warning
self.read32 = setup.read32
self.write32 = setup.write32
self.reg = GCpuReg(setup)

View file

@ -22,10 +22,6 @@ class legacyext(metaclass=LogBase):
def __init__(self, mtk, legacy, loglevel):
self.pathconfig = pathconfig()
self.__logger = logsetup(self, self.__logger, loglevel, mtk.config.gui)
self.info = self.__logger.info
self.debug = self.__logger.debug
self.error = self.__logger.error
self.warning = self.__logger.warning
self.mtk = mtk
self.loglevel = loglevel
self.__logger = self.__logger

View file

@ -20,9 +20,6 @@ class META(metaclass=LogBase):
def __init__(self, mtk, loglevel=logging.INFO):
self.mtk = mtk
self.__logger = logsetup(self, self.__logger, loglevel, mtk.config.gui)
self.info = self.__logger.info
self.debug = self.__logger.debug
self.error = self.__logger.error
self.gcpu = None
self.config = mtk.config
self.display = True

View file

@ -836,9 +836,6 @@ class DALegacy(metaclass=LogBase):
def __init__(self, mtk, daconfig, loglevel=logging.INFO):
self.__logger = logsetup(self, self.__logger, loglevel, mtk.config.gui)
self.debug = self.debug
self.error = self.error
self.info = self.info
self.emmc = None
self.nand = None
self.nor = None

View file

@ -139,10 +139,6 @@ class DAXFlash(metaclass=LogBase):
def __init__(self, mtk, daconfig, loglevel=logging.INFO):
self.__logger = logsetup(self, self.__logger, loglevel, mtk.config.gui)
self.info = self.__logger.info
self.debug = self.__logger.debug
self.error = self.__logger.error
self.warning = self.__logger.warning
self.mtk = mtk
self.loglevel = loglevel
self.daext = False
@ -542,11 +538,11 @@ class DAXFlash(metaclass=LogBase):
data[:(5 * 2)])
status = self.status()
if status == 0:
self.info("HW-CODE : 0x%X", chipid.hw_code)
self.info("HWSUB-CODE : 0x%X", chipid.hw_sub_code)
self.info("HW-VERSION : 0x%X", chipid.hw_version)
self.info("SW-VERSION : 0x%X", chipid.sw_version)
self.info("CHIP-EVOLUTION : 0x%X", chipid.chip_evolution)
self.info("HW-CODE : 0x%X" % chipid.hw_code)
self.info("HWSUB-CODE : 0x%X" % chipid.hw_sub_code)
self.info("HW-VERSION : 0x%X" % chipid.hw_version)
self.info("SW-VERSION : 0x%X" % chipid.sw_version)
self.info("CHIP-EVOLUTION : 0x%X" % chipid.chip_evolution)
return chipid
else:
self.error(f"Error on getting chip id: {self.eh.status(status)}")

View file

@ -43,10 +43,6 @@ class xflashext(metaclass=LogBase):
def __init__(self, mtk, xflash, loglevel):
self.pathconfig = pathconfig()
self.__logger = logsetup(self, self.__logger, loglevel, mtk.config.gui)
self.info = self.__logger.info
self.debug = self.__logger.debug
self.error = self.__logger.error
self.warning = self.__logger.warning
self.mtk = mtk
self.loglevel = loglevel
self.__logger = self.__logger