in reply to I need Hex conversion, not!
keep the hexnumbers as strings ...
DB<121> $SM = 0xFE; => 254 DB<122> $SM = "0xFE"; => "0xFE" DB<123> print $SM => 1 0xFE
...or write a subroutine printhex() which automatically fulfills your wishes by converting any numeric scalar to a hexstring before printing.
Cheers Rolf
|
|---|