MSM8916 fixes

This commit is contained in:
Bjoern Kerler 2020-01-10 12:59:01 +01:00
parent 775684a62f
commit a9f78898b3
3 changed files with 16 additions and 2 deletions

View file

@ -526,6 +526,16 @@ class qualcomm_firehose:
if rsp[0] == True:
self.cdc.read()
if not "MemoryName" in rsp[1]:
#print(rsp[1])
rsp[1]["MemoryName"]="eMMC"
if not "MaxXMLSizeInBytes" in rsp[1]:
rsp[1]["MaxXMLSizeInBytes"]="4096"
logging.warning("Couldn't detect MaxPayloadSizeFromTargetinBytes")
if not "MaxPayloadSizeToTargetInBytes" in rsp[1]:
rsp[1]["MaxPayloadSizeToTargetInBytes"] = "1038576"
if not "MaxPayloadSizeToTargetInBytesSupported" in rsp[1]:
rsp[1]["MaxPayloadSizeToTargetInBytesSupported"] = "1038576"
self.cfg.MemoryName = rsp[1]["MemoryName"]
self.cfg.MaxPayloadSizeToTargetInBytes = int(rsp[1]["MaxPayloadSizeToTargetInBytes"])
self.cfg.MaxPayloadSizeToTargetInBytesSupported = int(rsp[1]["MaxPayloadSizeToTargetInBytesSupported"])

View file

@ -156,7 +156,10 @@ class usb_class():
try:
logger.debug("TX: "+command.decode('utf-8'))
except:
logger.debug("TX: "+hexlify(command).decode('utf-8'))
try:
logger.debug("TX: "+hexlify(command).decode('utf-8'))
except:
logger.debug("TX: "+command)
return True
def read(self,length=0x80000, timeout=None):

View file

@ -1,4 +1,5 @@
pyusb
pyserial
docopt
pylzma
pylzma
pycryptodome