add global timeout for waitFor commands. Fixes #129

Fixes #129.