Changes to run file

Implemented the waiting similar to how Dr. Corwin showed us how to....
should be ready for testing.