Updates processing
fix crc error
Adds unit tests; fixes things found by unit tests