[EMAIL PROTECTED] wrote: > Hi all, > I want to read a serial comm port receiving hexa data. > Then i would like to print these data in ascii, i mean if i receive 0x41, i > would print "41" not the character "A". > > I try with the pack function but it doesn't work (surely because i don't > understand this function) > > Have you any idea ??
Does this give you any clues? Rob printf '%02X ', $_ foreach unpack 'C*', 'ABCDE'; **OUTPUT** 41 42 43 44 45 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/