# weiter oben steht noch use Encode; sub encode_7bit { my ($msg) = $_[0]; my ($bits, $ud, $octet); foreach (split(//,$msg)) { my $b = encode("gsm0338", $_); $b = unpack('b7', $b); $bits .= $b; } while (defined($bits) && (length($bits)>0)) { $octet = substr($bits."0" x 7,0,8); $ud .= unpack("H2", pack("b8", substr($octet, 0, 8))); $bits = (length($bits)>8)?substr($bits,8):""; } return uc $ud; }