You asked sysread to read 12 bytes, not 12 fields. unpack("I") will only decode one 32-bit value from the beginning of the buffer passed to it.
Do you have a C type structure definition or some other description for the data you are trying to parse?
My Pack/Unpack Tutorial might be helpful to you.
--- print map { my ($m)=1<<hex($_)&11?' ':''; $m.=substr('AHJPacehklnorstu',hex($_),1) } split //,'2fde0abe76c36c914586c';
In reply to Re: Binary data
by pfaut
in thread Binary data
by JunkGuy
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |