You're trying to store a 48bit number into a 32bit variable. mac2long is returning 2500998230 (0x95123456), while it should be returning 71220474966 (0x1095123456). You could use Math::BigInt.
By the way, "octet" means "8 bits", so the MAC addr is 6 (48/8) octets long, not 3.
In reply to Re: Help with Mac Address to Integer conversion
by ikegami
in thread Help with Mac Address to Integer conversion
by justintime
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |