added basic packet functionality