Encode Bytes

albert_k_arhin albert_k_arhin at yahoo.com
Wed Jul 11 14:40:02 EDT 2007


Hi All,
      I am new to python and I am using a strip down version of 
python that does not support struc,pack,etc.

I have a binary protocol that is define as follows:

  PART    OffSet     Lenght
============================
   ID       0            2
   VER      2            1
   CMD      3            2
   PGKID    5            2
   DATE     7            3
   TIME    10            3
   CRC     13            2
   DLEN    15            2

How do I encode these the offset is in Bytes.

Thank you very much.




More information about the Python-list mailing list