Put in a number of changes suggested in the code review. Includes a restructuring of the code, better error handling, detailed explanations, etc.
Fixed a bug with the most recent parser (missed a machine on the final instance in the files) and got rid of some left-over debug output.