Added countdown and trial loops along with completing the game loop.
Remaining work: integrate with the Brain-2-Brain project and TMS code