hex to bin 16 bit word

python w.g.sneddon at gmail.com
Sat Apr 28 10:06:51 EDT 2012


snip

Thanks for all you suggestions.

This was sent via email.  Original solution with struct was not
to bad but less clear that this was sent to me via email.

>>> import ctypes
>>> x = ctypes.c_int16(0xC08A)
>>> x.value
>>> -16246



More information about the Python-list mailing list