Finally figured out how to wait for the time to change on the device.
Final adjustment (I hope).
Fixed the last switchToFrame().
Merge pull request #127 from roydude/v1-train

V1 train