my $hexmsg = unpack("H*", $buffer); my @msg = ( $hexmsg =~ m/../g );