added unittest for chars from all octets
fixed bugs in pack-routine