나는 위치 이진 포맷이다파이썬을 풀고 이진 데이터
그러나 "회계 - 요청"패킷으로부터 위치를 잡고 반경위한 rlm_python 모듈
"\001\027\002\025\001+\001\024"
쓰고 구조체 사용
[[email protected] ~]# python
Python 2.4.3 (#1, May 5 2011, 16:39:10)
[GCC 4.1.2 20080704 (Red Hat 4.1.2-50)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> from struct import *
>>> unpack('hhl',"\001\027\002\025\001+\001\024")
Traceback (most recent call last):
File "<stdin>", line 1, in ?
struct.error: unpack str size does not match format
이 데이터를 어떻게 풀 수 있습니까?
바이너리 데이터가 아닌 * 8 진수 *가 있습니다. –
이것을 어떻게 변환 할 수 있습니까? – krisdigitx
'calcsize ('l')','calcsize ('= l')','calcsize ('i')'등 ('calcsize'는'struct.calcsize'입니다)을 비교하십시오. –