You are reading a single comment by @louisld and its replies. Click here to read the full conversation.
  • I tried several times but nothing changed. Here is my new code :

    var Ruuvitag = require("Ruuvitag");
    
    Ruuvitag.setEnvOn(true);
    
    NRF.setServices({
      0x1800: { // heart_rate
        0x2A6E: { // heart_rate_measurement
          notify: true,
          value : [Math.round(Ruuvitag.getEnvData().temp)]­,
        }
      }
    }, { advertise: [0x1801] });
    
    setInterval(function () {
      NRF.updateServices({
        0x1800: {
          0x2A6E: {
            value : [Math.round(Ruuvitag.getEnvData().temp)]­,
            notify: true
          }
        }
      });
    }, 1000);
    

    Here is what I get with my phone :

    It's says no service. And in the section "TX characteristic" I can see an error from the javascript interpreter but I'm not able to read it because it goes too fast.
    I don't understand why there is an error even with the IDE disconnected. The code looks very simple.

About

Avatar for louisld @louisld started