Re: Preliminary enV2/VX9100 Support
"Aaron G. Stemen" <[email protected]>
| Newsgroups | gmane.comp.mobile.bitpim.devel |
|---|---|
| Message-ID | <[email protected]> |
The current code allows users to navigate through the filesystem, but not read or write to it. The attached patch allows users to read and write the filesystem on their enV2. Something has changed that isn't allowing me to read/write data through the other features. I'll have to look into that some more. Enjoy. -A Joe Pham wrote: > I just committed some premilinary support to the VX9100: auto-detection and filesystem access. Please check it out and report any problems you may find. Ringtones may also be added into the next test release. > > -Joe Pham > > > ____________________________________________________________ > Beauty Advice Just Got a Makeover > Read reviews about the beauty products you have always wanted to try > http://thirdpartyoffers.netzero.net/TGL2231/fc/JKFkuJO6pwAd1h55sjcxqUCu4ty8j87RSh5usYfvyeY8S7b2Hiq20k/ > > ------------------------------------------------------------------------- > Check out the new SourceForge.net Marketplace. > It's the best place to buy or sell services for > just about anything Open Source. > http://sourceforge.net/services/buy/index.php > _______________________________________________ > BitPim-devel mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/bitpim-devel > ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ BitPim-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/bitpim-devel
VX9100_part2.patch
(text/plain, 23.8 KB)
Index: src/phones/com_lg.py
===================================================================
--- src/phones/com_lg.py (revision 4620)
+++ src/phones/com_lg.py (working copy)
@@ -1606,21 +1606,24 @@
def _enter_DMv6(self):
# similar but slightly different from v5, the enV2 started this!
# request the seed
- _req=self.protocolclass.DMKeyReq()
+ _req=self.protocolclass.DMKeyReq(unlock_key=0)
_resp=self.sendbrewcommand(_req, self.protocolclass.DMKeyResp)
_key=self.get_challenge_response(_resp.unlock_key)
+
if _key is None:
self.log('Failed to get the key.')
raise EnterDMError('Failed to get the key')
- _req=self.protocolclass.DMEnterReq(unlock_key=_key)
- if _resp.unlock_code==0:
- _req.unlock_code=1
- elif _resp.unlock_code==2:
- _req.unlock_code=3
- _req.convert_to_key2()
- else:
- raise EnterDMError('Unknown unlock_code: %d'%_resp.unlock_code)
+
+ xorkey = _key ^ 0xffffffffL
+ key0 = 0x86b206a0L
+ key1 = 0x86b200a0L | ((xorkey & 0x000000ffL) << 8)
+ key2 = 0xb8200033L | (xorkey & 0x0000ff00L)
+ key3 = 0x57410069L | ((xorkey & 0x00ff0000L) >> 8)
+ key4 = 0x8da4007fL | ((xorkey & 0xff000000L) >> 16)
+
+ _req = self.protocolclass.DMEnterReq(unlock_code=3, key0=key0, key1=key1, key2=key2, key3=key3, key4=key4)
_resp=self.sendbrewcommand(_req, self.protocolclass.DMEnterResp)
+
if _resp.result!=1:
raise EnterDMError('Bad response - unlock_ok: %d'%_resp.result)
@@ -1645,8 +1648,8 @@
except:
self.log('Failed to transition to DM')
self._in_DM=False
-## if __debug__:
-## raise
+ if __debug__:
+ raise
return
def _OnTimer(self):
Index: src/phones/com_lgvx9100.py
===================================================================
--- src/phones/com_lgvx9100.py (revision 4620)
+++ src/phones/com_lgvx9100.py (working copy)
@@ -106,21 +106,23 @@
return self.imagetargets
_supportedsyncs=(
-## ('phonebook', 'read', None), # all phonebook reading
-## ('calendar', 'read', None), # all calendar reading
-## ('wallpaper', 'read', None), # all wallpaper reading
-## ('ringtone', 'read', None), # all ringtone reading
-## ('call_history', 'read', None),# all call history list reading
-## ('sms', 'read', None), # all SMS list reading
-## ('memo', 'read', None), # all memo list reading
-## ('phonebook', 'write', 'OVERWRITE'), # only overwriting phonebook
-## ('calendar', 'write', 'OVERWRITE'), # only overwriting calendar
-## ('wallpaper', 'write', 'MERGE'), # merge and overwrite wallpaper
-## ('wallpaper', 'write', 'OVERWRITE'),
-## ('ringtone', 'write', 'MERGE'), # merge and overwrite ringtone
-## ('ringtone', 'write', 'OVERWRITE'),
-#### ('sms', 'write', 'OVERWRITE'), # all SMS list writing
-## ('memo', 'write', 'OVERWRITE'), # all memo list writing
-#### ('playlist', 'read', 'OVERWRITE'),
-#### ('playlist', 'write', 'OVERWRITE'),
+ ('phonebook', 'read', None), # all phonebook reading
+ ('calendar', 'read', None), # all calendar reading
+ ('wallpaper', 'read', None), # all wallpaper reading
+ ('ringtone', 'read', None), # all ringtone reading
+ ('call_history', 'read', None),# all call history list reading
+ ('sms', 'read', None), # all SMS list reading
+ ('memo', 'read', None), # all memo list reading
+ ('t9_udb', 'read', 'OVERWRITE'),
+ ('phonebook', 'write', 'OVERWRITE'), # only overwriting phonebook
+ ('calendar', 'write', 'OVERWRITE'), # only overwriting calendar
+ ('wallpaper', 'write', 'MERGE'), # merge and overwrite wallpaper
+ ('wallpaper', 'write', 'OVERWRITE'),
+ ('ringtone', 'write', 'MERGE'), # merge and overwrite ringtone
+ ('ringtone', 'write', 'OVERWRITE'),
+ ('sms', 'write', 'OVERWRITE'), # all SMS list writing
+ ('memo', 'write', 'OVERWRITE'), # all memo list writing
+## ('playlist', 'read', 'OVERWRITE'),
+## ('playlist', 'write', 'OVERWRITE'),
+ ('t9_udb', 'write', 'OVERWRITE'),
)
Index: src/phones/p_lg.p
===================================================================
--- src/phones/p_lg.p (revision 4620)
+++ src/phones/p_lg.p (working copy)
@@ -144,7 +144,7 @@
1 UINT { 'default': 0x00 } +unlock_code
4 UINT unlock_key
1 UINT { 'default': 0x00 } +zero
-
+
PACKET ULRes:
""
1 UINT cmd
@@ -154,7 +154,7 @@
PACKET DMKeyReq:
"Slightly different command for DMv6"
- 1 UINT { 'default': 0xFE } +cmd
+ 1 UINT { 'constant': 0xFE } +cmd
1 UINT { 'default': 0x00 } +unlock_code
4 UINT { 'default': 0x00 } +unlock_key
1 UINT { 'default': 0x00 } +zero
@@ -168,42 +168,22 @@
PACKET DMEnterReq:
"Request to transition to DMv6"
- 1 UINT { 'default': 0xFE } +cmd
- 1 UINT { 'default': 0x00 } +unlock_code
- 4 UINT { 'default': 0x00 } +unlock_key
- 1 UINT { 'default': 0x00 } +zero
- 1 UINT { 'default': 0x00 } +option
- if self.unlock_code==3:
- * LIST { 'createdefault': True,
- 'length': 16 } +unlock_key2:
- 1 UINT { 'default': 0 } +data
- %{
+ 1 UINT { 'constant': 0xFE } +cmd
+ 1 UINT { 'default': 0x03 } +unlock_code
+ 4 UINT key0
+ 2 UINT { 'default': 0x00 } +zero
+ 4 UINT key1
+ 4 UINT key2
+ 4 UINT key3
+ 4 UINT key4
- def init_key2(self):
- if self.unlock_code==3 and \
- not len(self.unlock_key2):
- for _idx in range(16):
- self.unlock_key2.append(0)
-
- def convert_to_key2(self):
- """Convert the key value to key2"""
- if self.unlock_code!=3:
- return
- self.init_key2()
- _buf=buffer()
- UINT(sizeinbytes=4, value=self.unlock_key).writetobuffer(_buf)
- _key=_buf.getvalue()
- for _idx in range(4):
- self.unlock_key2[_idx*4]=~ord(_key[_idx])
-
- %}
-
PACKET DMEnterResp:
"Response to our request to enter DMv6"
1 UINT cmd
1 UINT unlock_code
4 UINT unlock_key
1 UINT result "0=Failure, 1=Success"
-
+ * DATA bytes
+
PACKET data:
* DATA bytes
Index: src/phones/p_lg.py
===================================================================
--- src/phones/p_lg.py (revision 4620)
+++ src/phones/p_lg.py (working copy)
@@ -2346,7 +2346,7 @@
self._bufferstartoffset=buf.getcurrentoffset()
try: self.__field_cmd
except:
- self.__field_cmd=UINT(**{'sizeinbytes': 1, 'default': 0xFE })
+ self.__field_cmd=UINT(**{'sizeinbytes': 1, 'constant': 0xFE })
self.__field_cmd.writetobuffer(buf)
try: self.__field_unlock_code
except:
@@ -2372,7 +2372,7 @@
'Reads this packet from the supplied buffer'
self._bufferstartoffset=buf.getcurrentoffset()
if autolog and self._bufferstartoffset==0: self.autologread(buf, logtitle=logtitle)
- self.__field_cmd=UINT(**{'sizeinbytes': 1, 'default': 0xFE })
+ self.__field_cmd=UINT(**{'sizeinbytes': 1, 'constant': 0xFE })
self.__field_cmd.readfrombuffer(buf)
self.__field_unlock_code=UINT(**{'sizeinbytes': 1, 'default': 0x00 })
self.__field_unlock_code.readfrombuffer(buf)
@@ -2388,14 +2388,14 @@
def __getfield_cmd(self):
try: self.__field_cmd
except:
- self.__field_cmd=UINT(**{'sizeinbytes': 1, 'default': 0xFE })
+ self.__field_cmd=UINT(**{'sizeinbytes': 1, 'constant': 0xFE })
return self.__field_cmd.getvalue()
def __setfield_cmd(self, value):
if isinstance(value,UINT):
self.__field_cmd=value
else:
- self.__field_cmd=UINT(value,**{'sizeinbytes': 1, 'default': 0xFE })
+ self.__field_cmd=UINT(value,**{'sizeinbytes': 1, 'constant': 0xFE })
def __delfield_cmd(self): del self.__field_cmd
@@ -2585,7 +2585,7 @@
class DMEnterReq(BaseProtogenClass):
"Request to transition to DMv6"
- __fields=['cmd', 'unlock_code', 'unlock_key', 'zero', 'option', 'unlock_key2']
+ __fields=['cmd', 'unlock_code', 'key0', 'zero', 'key1', 'key2', 'key3', 'key4']
def __init__(self, *args, **kwargs):
dict={}
@@ -2620,29 +2620,21 @@
self._bufferstartoffset=buf.getcurrentoffset()
try: self.__field_cmd
except:
- self.__field_cmd=UINT(**{'sizeinbytes': 1, 'default': 0xFE })
+ self.__field_cmd=UINT(**{'sizeinbytes': 1, 'constant': 0xFE })
self.__field_cmd.writetobuffer(buf)
try: self.__field_unlock_code
except:
- self.__field_unlock_code=UINT(**{'sizeinbytes': 1, 'default': 0x00 })
+ self.__field_unlock_code=UINT(**{'sizeinbytes': 1, 'default': 0x03 })
self.__field_unlock_code.writetobuffer(buf)
- try: self.__field_unlock_key
- except:
- self.__field_unlock_key=UINT(**{'sizeinbytes': 4, 'default': 0x00 })
- self.__field_unlock_key.writetobuffer(buf)
+ self.__field_key0.writetobuffer(buf)
try: self.__field_zero
except:
- self.__field_zero=UINT(**{'sizeinbytes': 1, 'default': 0x00 })
+ self.__field_zero=UINT(**{'sizeinbytes': 2, 'default': 0x00 })
self.__field_zero.writetobuffer(buf)
- try: self.__field_option
- except:
- self.__field_option=UINT(**{'sizeinbytes': 1, 'default': 0x00 })
- self.__field_option.writetobuffer(buf)
- if self.unlock_code==3:
- try: self.__field_unlock_key2
- except:
- self.__field_unlock_key2=LIST(**{'elementclass': _gen_p_lg_179, 'createdefault': True, 'length': 16 })
- self.__field_unlock_key2.writetobuffer(buf)
+ self.__field_key1.writetobuffer(buf)
+ self.__field_key2.writetobuffer(buf)
+ self.__field_key3.writetobuffer(buf)
+ self.__field_key4.writetobuffer(buf)
self._bufferendoffset=buf.getcurrentoffset()
if autolog and self._bufferstartoffset==0: self.autologwrite(buf, logtitle=logtitle)
@@ -2651,33 +2643,36 @@
'Reads this packet from the supplied buffer'
self._bufferstartoffset=buf.getcurrentoffset()
if autolog and self._bufferstartoffset==0: self.autologread(buf, logtitle=logtitle)
- self.__field_cmd=UINT(**{'sizeinbytes': 1, 'default': 0xFE })
+ self.__field_cmd=UINT(**{'sizeinbytes': 1, 'constant': 0xFE })
self.__field_cmd.readfrombuffer(buf)
- self.__field_unlock_code=UINT(**{'sizeinbytes': 1, 'default': 0x00 })
+ self.__field_unlock_code=UINT(**{'sizeinbytes': 1, 'default': 0x03 })
self.__field_unlock_code.readfrombuffer(buf)
- self.__field_unlock_key=UINT(**{'sizeinbytes': 4, 'default': 0x00 })
- self.__field_unlock_key.readfrombuffer(buf)
- self.__field_zero=UINT(**{'sizeinbytes': 1, 'default': 0x00 })
+ self.__field_key0=UINT(**{'sizeinbytes': 4})
+ self.__field_key0.readfrombuffer(buf)
+ self.__field_zero=UINT(**{'sizeinbytes': 2, 'default': 0x00 })
self.__field_zero.readfrombuffer(buf)
- self.__field_option=UINT(**{'sizeinbytes': 1, 'default': 0x00 })
- self.__field_option.readfrombuffer(buf)
- if self.unlock_code==3:
- self.__field_unlock_key2=LIST(**{'elementclass': _gen_p_lg_179, 'createdefault': True, 'length': 16 })
- self.__field_unlock_key2.readfrombuffer(buf)
+ self.__field_key1=UINT(**{'sizeinbytes': 4})
+ self.__field_key1.readfrombuffer(buf)
+ self.__field_key2=UINT(**{'sizeinbytes': 4})
+ self.__field_key2.readfrombuffer(buf)
+ self.__field_key3=UINT(**{'sizeinbytes': 4})
+ self.__field_key3.readfrombuffer(buf)
+ self.__field_key4=UINT(**{'sizeinbytes': 4})
+ self.__field_key4.readfrombuffer(buf)
self._bufferendoffset=buf.getcurrentoffset()
def __getfield_cmd(self):
try: self.__field_cmd
except:
- self.__field_cmd=UINT(**{'sizeinbytes': 1, 'default': 0xFE })
+ self.__field_cmd=UINT(**{'sizeinbytes': 1, 'constant': 0xFE })
return self.__field_cmd.getvalue()
def __setfield_cmd(self, value):
if isinstance(value,UINT):
self.__field_cmd=value
else:
- self.__field_cmd=UINT(value,**{'sizeinbytes': 1, 'default': 0xFE })
+ self.__field_cmd=UINT(value,**{'sizeinbytes': 1, 'constant': 0xFE })
def __delfield_cmd(self): del self.__field_cmd
@@ -2686,201 +2681,119 @@
def __getfield_unlock_code(self):
try: self.__field_unlock_code
except:
- self.__field_unlock_code=UINT(**{'sizeinbytes': 1, 'default': 0x00 })
+ self.__field_unlock_code=UINT(**{'sizeinbytes': 1, 'default': 0x03 })
return self.__field_unlock_code.getvalue()
def __setfield_unlock_code(self, value):
if isinstance(value,UINT):
self.__field_unlock_code=value
else:
- self.__field_unlock_code=UINT(value,**{'sizeinbytes': 1, 'default': 0x00 })
+ self.__field_unlock_code=UINT(value,**{'sizeinbytes': 1, 'default': 0x03 })
def __delfield_unlock_code(self): del self.__field_unlock_code
unlock_code=property(__getfield_unlock_code, __setfield_unlock_code, __delfield_unlock_code, None)
- def __getfield_unlock_key(self):
- try: self.__field_unlock_key
- except:
- self.__field_unlock_key=UINT(**{'sizeinbytes': 4, 'default': 0x00 })
- return self.__field_unlock_key.getvalue()
+ def __getfield_key0(self):
+ return self.__field_key0.getvalue()
- def __setfield_unlock_key(self, value):
+ def __setfield_key0(self, value):
if isinstance(value,UINT):
- self.__field_unlock_key=value
+ self.__field_key0=value
else:
- self.__field_unlock_key=UINT(value,**{'sizeinbytes': 4, 'default': 0x00 })
+ self.__field_key0=UINT(value,**{'sizeinbytes': 4})
- def __delfield_unlock_key(self): del self.__field_unlock_key
+ def __delfield_key0(self): del self.__field_key0
- unlock_key=property(__getfield_unlock_key, __setfield_unlock_key, __delfield_unlock_key, None)
+ key0=property(__getfield_key0, __setfield_key0, __delfield_key0, None)
def __getfield_zero(self):
try: self.__field_zero
except:
- self.__field_zero=UINT(**{'sizeinbytes': 1, 'default': 0x00 })
+ self.__field_zero=UINT(**{'sizeinbytes': 2, 'default': 0x00 })
return self.__field_zero.getvalue()
def __setfield_zero(self, value):
if isinstance(value,UINT):
self.__field_zero=value
else:
- self.__field_zero=UINT(value,**{'sizeinbytes': 1, 'default': 0x00 })
+ self.__field_zero=UINT(value,**{'sizeinbytes': 2, 'default': 0x00 })
def __delfield_zero(self): del self.__field_zero
zero=property(__getfield_zero, __setfield_zero, __delfield_zero, None)
- def __getfield_option(self):
- try: self.__field_option
- except:
- self.__field_option=UINT(**{'sizeinbytes': 1, 'default': 0x00 })
- return self.__field_option.getvalue()
+ def __getfield_key1(self):
+ return self.__field_key1.getvalue()
- def __setfield_option(self, value):
+ def __setfield_key1(self, value):
if isinstance(value,UINT):
- self.__field_option=value
+ self.__field_key1=value
else:
- self.__field_option=UINT(value,**{'sizeinbytes': 1, 'default': 0x00 })
+ self.__field_key1=UINT(value,**{'sizeinbytes': 4})
- def __delfield_option(self): del self.__field_option
+ def __delfield_key1(self): del self.__field_key1
- option=property(__getfield_option, __setfield_option, __delfield_option, None)
+ key1=property(__getfield_key1, __setfield_key1, __delfield_key1, None)
- def __getfield_unlock_key2(self):
- try: self.__field_unlock_key2
- except:
- self.__field_unlock_key2=LIST(**{'elementclass': _gen_p_lg_179, 'createdefault': True, 'length': 16 })
- return self.__field_unlock_key2.getvalue()
+ def __getfield_key2(self):
+ return self.__field_key2.getvalue()
- def __setfield_unlock_key2(self, value):
- if isinstance(value,LIST):
- self.__field_unlock_key2=value
+ def __setfield_key2(self, value):
+ if isinstance(value,UINT):
+ self.__field_key2=value
else:
- self.__field_unlock_key2=LIST(value,**{'elementclass': _gen_p_lg_179, 'createdefault': True, 'length': 16 })
+ self.__field_key2=UINT(value,**{'sizeinbytes': 4})
- def __delfield_unlock_key2(self): del self.__field_unlock_key2
+ def __delfield_key2(self): del self.__field_key2
- unlock_key2=property(__getfield_unlock_key2, __setfield_unlock_key2, __delfield_unlock_key2, None)
+ key2=property(__getfield_key2, __setfield_key2, __delfield_key2, None)
- def iscontainer(self):
- return True
+ def __getfield_key3(self):
+ return self.__field_key3.getvalue()
- def containerelements(self):
- yield ('cmd', self.__field_cmd, None)
- yield ('unlock_code', self.__field_unlock_code, None)
- yield ('unlock_key', self.__field_unlock_key, None)
- yield ('zero', self.__field_zero, None)
- yield ('option', self.__field_option, None)
- if self.unlock_code==3:
- yield ('unlock_key2', self.__field_unlock_key2, None)
+ def __setfield_key3(self, value):
+ if isinstance(value,UINT):
+ self.__field_key3=value
+ else:
+ self.__field_key3=UINT(value,**{'sizeinbytes': 4})
+ def __delfield_key3(self): del self.__field_key3
- def init_key2(self):
- if self.unlock_code==3 and \
- not len(self.unlock_key2):
- for _idx in range(16):
- self.unlock_key2.append(0)
+ key3=property(__getfield_key3, __setfield_key3, __delfield_key3, None)
- def convert_to_key2(self):
- """Convert the key value to key2"""
- if self.unlock_code!=3:
- return
- self.init_key2()
- _buf=buffer()
- UINT(sizeinbytes=4, value=self.unlock_key).writetobuffer(_buf)
- _key=_buf.getvalue()
- for _idx in range(4):
- self.unlock_key2[_idx*4]=~ord(_key[_idx])
+ def __getfield_key4(self):
+ return self.__field_key4.getvalue()
-
-
-
-
-class _gen_p_lg_179(BaseProtogenClass):
- 'Anonymous inner class'
- __fields=['data']
-
- def __init__(self, *args, **kwargs):
- dict={}
- # What was supplied to this function
- dict.update(kwargs)
- # Parent constructor
- super(_gen_p_lg_179,self).__init__(**dict)
- if self.__class__ is _gen_p_lg_179:
- self._update(args,dict)
-
-
- def getfields(self):
- return self.__fields
-
-
- def _update(self, args, kwargs):
- super(_gen_p_lg_179,self)._update(args,kwargs)
- keys=kwargs.keys()
- for key in keys:
- if key in self.__fields:
- setattr(self, key, kwargs[key])
- del kwargs[key]
- # Were any unrecognized kwargs passed in?
- if __debug__:
- self._complainaboutunusedargs(_gen_p_lg_179,kwargs)
- if len(args):
- dict2={'sizeinbytes': 1, 'default': 0 }
- dict2.update(kwargs)
- kwargs=dict2
- self.__field_data=UINT(*args,**dict2)
- # Make all P fields that haven't already been constructed
-
-
- def writetobuffer(self,buf,autolog=True,logtitle="<written data>"):
- 'Writes this packet to the supplied buffer'
- self._bufferstartoffset=buf.getcurrentoffset()
- try: self.__field_data
- except:
- self.__field_data=UINT(**{'sizeinbytes': 1, 'default': 0 })
- self.__field_data.writetobuffer(buf)
- self._bufferendoffset=buf.getcurrentoffset()
- if autolog and self._bufferstartoffset==0: self.autologwrite(buf, logtitle=logtitle)
-
-
- def readfrombuffer(self,buf,autolog=True,logtitle="<read data>"):
- 'Reads this packet from the supplied buffer'
- self._bufferstartoffset=buf.getcurrentoffset()
- if autolog and self._bufferstartoffset==0: self.autologread(buf, logtitle=logtitle)
- self.__field_data=UINT(**{'sizeinbytes': 1, 'default': 0 })
- self.__field_data.readfrombuffer(buf)
- self._bufferendoffset=buf.getcurrentoffset()
-
-
- def __getfield_data(self):
- try: self.__field_data
- except:
- self.__field_data=UINT(**{'sizeinbytes': 1, 'default': 0 })
- return self.__field_data.getvalue()
-
- def __setfield_data(self, value):
+ def __setfield_key4(self, value):
if isinstance(value,UINT):
- self.__field_data=value
+ self.__field_key4=value
else:
- self.__field_data=UINT(value,**{'sizeinbytes': 1, 'default': 0 })
+ self.__field_key4=UINT(value,**{'sizeinbytes': 4})
- def __delfield_data(self): del self.__field_data
+ def __delfield_key4(self): del self.__field_key4
- data=property(__getfield_data, __setfield_data, __delfield_data, None)
+ key4=property(__getfield_key4, __setfield_key4, __delfield_key4, None)
def iscontainer(self):
return True
def containerelements(self):
- yield ('data', self.__field_data, None)
+ yield ('cmd', self.__field_cmd, None)
+ yield ('unlock_code', self.__field_unlock_code, None)
+ yield ('key0', self.__field_key0, None)
+ yield ('zero', self.__field_zero, None)
+ yield ('key1', self.__field_key1, None)
+ yield ('key2', self.__field_key2, None)
+ yield ('key3', self.__field_key3, None)
+ yield ('key4', self.__field_key4, None)
class DMEnterResp(BaseProtogenClass):
"Response to our request to enter DMv6"
- __fields=['cmd', 'unlock_code', 'unlock_key', 'result']
+ __fields=['cmd', 'unlock_code', 'unlock_key', 'result', 'bytes']
def __init__(self, *args, **kwargs):
dict={}
@@ -2917,6 +2830,7 @@
self.__field_unlock_code.writetobuffer(buf)
self.__field_unlock_key.writetobuffer(buf)
self.__field_result.writetobuffer(buf)
+ self.__field_bytes.writetobuffer(buf)
self._bufferendoffset=buf.getcurrentoffset()
if autolog and self._bufferstartoffset==0: self.autologwrite(buf, logtitle=logtitle)
@@ -2933,6 +2847,8 @@
self.__field_unlock_key.readfrombuffer(buf)
self.__field_result=UINT(**{'sizeinbytes': 1})
self.__field_result.readfrombuffer(buf)
+ self.__field_bytes=DATA()
+ self.__field_bytes.readfrombuffer(buf)
self._bufferendoffset=buf.getcurrentoffset()
@@ -2988,6 +2904,19 @@
result=property(__getfield_result, __setfield_result, __delfield_result, "0=Failure, 1=Success")
+ def __getfield_bytes(self):
+ return self.__field_bytes.getvalue()
+
+ def __setfield_bytes(self, value):
+ if isinstance(value,DATA):
+ self.__field_bytes=value
+ else:
+ self.__field_bytes=DATA(value,)
+
+ def __delfield_bytes(self): del self.__field_bytes
+
+ bytes=property(__getfield_bytes, __setfield_bytes, __delfield_bytes, None)
+
def iscontainer(self):
return True
@@ -2996,6 +2925,7 @@
yield ('unlock_code', self.__field_unlock_code, None)
yield ('unlock_key', self.__field_unlock_key, None)
yield ('result', self.__field_result, "0=Failure, 1=Success")
+ yield ('bytes', self.__field_bytes, None)