add serial outputs, cleaned up code, renamed file