Add a preparse callback
Add logging support by using the preparse callback
Fix typos in tap_parser_reset