Added packet decoder and encoder.