tessel/runtime — pull request #625 by tcr (2014-11-07 23:59:25+00:00)
Title: Corrects newly added timers to not invoke early.

Timers can enter a race condition where if they are added, and the "elapsed" variable is sufficiently large, then it will consider the newly added timer as being invoked immediately.

```
INFO Bundling directory /Users/tim/Code/technical/workspace/firmware/test
INFO Deploying bundle (1.65 MB)...
INFO Running script...
~~~> time 0 elapsed 176
~~~> time 0 elapsed 176
TAP version 13
~~~> time 29812 elapsed 176
~~~> time 29636 elapsed 1990166 (!!!)
# small async transfer
ADD NEW 1S TIMER
~~~> time 1000000 elapsed 1960530 (!!!)
--> failed at [ 0, 274179072 ]
--> failed at : 0 0.073485824
not ok 1 test timed out
---
operator: fail
...
```

See that the "ADD NEW 1S TIMER" is evaluated using the elapsed time that was sampled at the beginning of the loop it is inside. (The difference in elapsed time is due to elapsed time being subtracted by the counter to keep ordering consistent)