I'm trying to use an ESP8226 and I managed to screw up a couple of picos while trying to solder on the ESP8226 shim. I no longer have shims for the ESP8226 and I am now using: https://www.sparkfun.com/products/13287 There is a switch located on the sparkfun's ESP8266 shield for Software Serial and Hardware Serial. I'm using the Software Serial pins on the ESP8266 shield and used jumper wires from the Hardware Serial RX and TX to pin A2 and A3 for successful communication.
I'm assuming that I should use the serial baud rate of 115200 because the ESP8226 firmware is 0.30.0.0?
I am now attempting to get basic communication from the ESP8226 and using the code below. However, I am receiving
Module NetworkJS not found
and
Module http not found
Code:
Serial2.setup(115200, { rx: A3, tx : A2 });
var wifi = require("ESP8266WiFi_0v25").connect(Serial2, function(err) {
// ^^^^^^^^^^^^^^^^
// Use ESP8266WiFi here (and 9600 baud) if you have an ESP8266 with firmware older than 0.25
if (err) throw err;
wifi.reset(function(err) {
if (err) throw err;
console.log("Connecting to WiFi");
wifi.connect("WiFi_Name","WPA2_Key", function(err) {
if (err) throw err;
console.log("Connected");
// Now you can do something, like an HTTP request
require("http").get("http://www.pur3.co.uk/hello.txt", function(res) {
console.log("Response: ",res);
res.on('data', function(d) {
console.log("--->"+d);
});
});
});
});
});
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
I'm trying to use an ESP8226 and I managed to screw up a couple of picos while trying to solder on the ESP8226 shim. I no longer have shims for the ESP8226 and I am now using: https://www.sparkfun.com/products/13287 There is a switch located on the sparkfun's ESP8266 shield for Software Serial and Hardware Serial. I'm using the Software Serial pins on the ESP8266 shield and used jumper wires from the Hardware Serial RX and TX to pin A2 and A3 for successful communication.
I ran the firmware js code:
Which resulted:
I'm assuming that I should use the serial baud rate of 115200 because the ESP8226 firmware is 0.30.0.0?
I am now attempting to get basic communication from the ESP8226 and using the code below. However, I am receiving
and
Code: