• Hi! I'm pretty sure you've his exactly this issue that was reported a few days ago: http://forum.espruino.com/conversations/­363920/#comment15998892

    I have no idea why this has happened yet but I will look into it very soon. For the moment you can almost certainly fix it by changing:

        return device.gatt.connect();
      }).then(function(g) {
        logMsg += "Connected\n";
        digitalPulse(LED3,1,10);
        gatt = g;
        return g.getPrimaryService(primaryServiceUuid);­
      }).then(function(service) {
    

    to:

        return device.gatt.connect();
      }).then(function(g) {
        logMsg += "Connected\n";
        digitalPulse(LED3,1,10);
        gatt = g;
        return new Promise(r => setTimeout(r,500)); //< ---------- added this delay
      }).then(function() {
        return gatt.getPrimaryService(primaryServiceUui­d);
      }).then(function(service) {
    ...
    
About

Avatar for Gordon @Gordon started