Fix packet parsing, start work on serial parser

The serial parser still doesn't correctly detect packets and tries to parse
clearly invalid data at times.