Guys, i need help! I have a wemos micro(esp8266 + cp 2102) and yesterday i’ve uploaded my sketch:
#include <ESP8266WiFi.h>
#include <BlynkSimpleEsp8266.h>
//#define BLYNK_PRINT Serial
char auth[] = "";
char ssid[] = "";
char pass[] = "";
int jsx, jsy, jdx, jdy, b1, b2, b3, b4;
void setup()
{
Serial.begin(9600);
Blynk.begin(auth, ssid, pass);
}
BLYNK_WRITE(V0)
{
b1 = param.asInt();
SerialWrite();
}
BLYNK_WRITE(V3)
{
b2 = param.asInt();
SerialWrite();
}
BLYNK_WRITE(V4)
{
b3 = param.asInt();
SerialWrite();
}
BLYNK_WRITE(V5)
{
b4 = param.asInt();
SerialWrite();
}
BLYNK_WRITE(V1)
{
jsx = param[0].asInt();
jsy = param[1].asInt();
SerialWrite();
}
BLYNK_WRITE(V2)
{
jdx = param[0].asInt();
jdy = param[1].asInt();
SerialWrite();
}
void loop()
{
Blynk.run();
}
void SerialWrite()
{
Serial.print(jsx);
Serial.print(" ");
Serial.print(jsy);
Serial.print(" ");
Serial.print(jdx);
Serial.print(" ");
Serial.print(jdy);
Serial.print(" ");
Serial.print(b1);
Serial.print(" ");
Serial.print(b2);
Serial.print(" ");
Serial.print(b3);
Serial.print(" ");
Serial.print(b4);
Serial.print("\n");
}
It was working very well until today when esp just doesn’t showed connected on the blynk app! So, i tried to reupload the sketch but i was getting this:
“warning: espcomm_sync failed
error: espcomm_open failed
error: espcomm_upload_mem failed”
I thought my esp died but suddenly esp start working again.(I forget it plug in and after 2 hour i find it connected). But now, when i restart it, it stop working again!
My hardware is: Wemos micro(esp8266), latest blynk library, latest arduino version.
Any idea? Is chip dead or is something wrong with the board?
P.S. I hook up the esp to an amperemeter and it draws about 100 - 80 mA.