added byte packing support