Replies: 1 comment 5 replies
-
|
Apart from the loading animations which are a separate app, nothing else uses jstimer afaik. setTimeout() and setInterval() don't interrupt execution so don't use jstimer. jstimer is not implemented in Emscripten because we don't really have such a thing as a separate timer. We'd have to have maybe a separate thread, or to add code that constantly polled during execution. It's be a massive pain to do, probably a big hack, and as we have no vibration motor anyway it didn't seem worth my effort implementing it. At the end of the day, the emulator is just meant to be a quick tool for checking things and developing simple apps. I just don't have the time to spend ages making it behave exactly like the real watch.
I don't believe so, no. How are you trying to check for long presses? That is handled by |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi, @gfwilliams, in Espruino commit eb017e0, you mention that the emulator "doesn't implement jstimer". Could you elaborate on that?
jstimerimplemented?Bangle.buzz()promise resolves without any delay, for one. What else?setTimeout()andsetInterval()do work, so... is that because they use some other timing mechanism? In general, or as a workaround in the emulator?Beta Was this translation helpful? Give feedback.
All reactions