Test if running on real device? #5537
Unanswered
espruino-discuss2
asked this question in
Bangle.js
Replies: 1 comment
-
Posted at 2023-01-07 by @fanoush maybe there is better version but check output of
so you may test process.env.BOARD or the SERIAL Posted at 2023-01-07 by BillV Thanks a lot, @fanoush, just what I wanted. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Posted at 2023-01-07 by BillV
Is it possible to test whether an app is running in the IDE or on a real device (Bangle 2)? For example, E.getBattery() always returns zero in the IDE so it's hard to check if a low charge warning is needed. Thanks and sorry if I'm missing something obvious!
Beta Was this translation helpful? Give feedback.
All reactions