Changes to support custom packets