added crc check
hack removed due to crc check
added ip field
some refactoring