Merge pull request #484 from Microsoft/bug_395_fix

Add eventTimestamp and eventValue to pxsim.control
This commit is contained in:
Caitlin Hennessy 2017-08-02 10:49:23 -07:00 committed by GitHub
commit 9b7a81c41b
2 changed files with 9 additions and 1 deletions

View File

@ -38,6 +38,6 @@
"semantic-ui-less": "^2.2.4"
},
"dependencies": {
"pxt-core": "0.12.103"
"pxt-core": "0.12.104"
}
}

View File

@ -65,6 +65,14 @@ namespace pxsim.control {
// TODO mode?
board().bus.queue(id, evid)
}
export function eventTimestamp() {
return board().bus.getLastEventTime()
}
export function eventValue() {
return board().bus.getLastEventValue()
}
}
namespace pxsim.pxtcore {