Changed the coding endocing to assume packet/4 since that is the format.

A utility module is added in test to make manual testing easier.