def _parseinfoeldse_(s):
""" :returns: parsed dse location from packed string s """
dse = {}
for n,i,l,x,f in _EID_DSE_FIELDS_:
if n == 'lat-int' or n == 'lon-int' or n == 'alt-int':
dse[n] = int2s(s[i:i+l]+'\x00'*x)
else:
dse[n] = struct.unpack_from(f,s[i:i+l]+'\x00'*x)
# last three fields are byte centric
dei,op,chn = struct.unpack_from('=H2B',s,len(s)-4)
dse['depend-enable-id'] = dei
dse['op-class'] = op
dse['ch-num'] = chn
return dse
# HT Capabilities Info field Std Fig 8-249
# octest are defined as 1|1|2|1|1|1|1|2|1|1|1|1|1|1 see Fig 8-249 for names
# See also Std Table 8-124 for definition of sub fields
评论列表
文章目录