Finished initial coding of latency testing script