• Ok, something is odd here, are you sure it's the code you posted earlier:

    var delay=5000;
    Serial2.setup(9600, { rx: A3, tx : A2 });
    var wifi = require("ESP8266WiFi").connect(Serial2, function(err) {
      if (err) throw err;
      wifi.reset(function(err) {
        if (err) throw err;
        console.log("Waiting for ESP8266 to flush its serial buffer");
        setTimeout(function(){
          //your code to be executed after 1 seconds
          wifi.connect("solarsystem","tmpjoimc", function(err) {
          if (err) throw err;
          console.log("Connected");
          // Now you can do something, like an HTTP request
        }); //wifi.connect
        }, delay); //setTimeOut
      }); //wifi.reset
    }); //require
    

    Because Espruino seems to be trying to reset and connect twice in a row from the log you posted...

About

Avatar for Gordon @Gordon started