• Could you try putting a try...catch around that just in case? It shouldn't be needed but would help to track down where the exception comes from

  • ok, I got I2C error but I don't quite understand this. try...catch catches something but still output says that there is uncaught error.

    Output:

    23.60415923008
    23.60415923008
    OUTER: undefined
    Uncaught Error: Unhandled promise rejection: Error: I2C Error: Arbitration (start)
    23.64360367590
    23.64360367590
    

    Code:

    setInterval(() => {
      try {
        Bangle.getPressure().then(d => {
          console.log(d.temperature);
        }).catch(error => {
          console.log("INNER: " + error);
        });
      } catch (error) {
        console.log("OUTER: " + error);
      }
    }, 10 * 1000);
    
About

Avatar for malaire @malaire started