Hi
Just getting started on a new app and I wanted to try things out on the emulator before I do anything with the watch, this is the way I have played with a lot of other peoples code on here and I really like that I can do that with this IDE.
That said I have a part of my current project that asks the bangle if it is charging (just simple Bangle.isCharging() ) and that course the emulator to fail.
As this is not an important value for the app I am doing, I was wondering if there was a way to set values for things like this when in the emulator?
I mean is there a way to check if the code is being run in an emulator and as such be able to suply value to get it to run?
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
Hi
Just getting started on a new app and I wanted to try things out on the emulator before I do anything with the watch, this is the way I have played with a lot of other peoples code on here and I really like that I can do that with this IDE.
That said I have a part of my current project that asks the bangle if it is charging (just simple Bangle.isCharging() ) and that course the emulator to fail.
As this is not an important value for the app I am doing, I was wondering if there was a way to set values for things like this when in the emulator?
I mean is there a way to check if the code is being run in an emulator and as such be able to suply value to get it to run?