Dasduino Connect ESP8266 upload fails with timeout waiting for packet header

Customer:

I’ve made some progress on my project. Now Arduino IDE is giving me this error message:

Executable segment sizes:

ICAM : 32768 – flash instruction cache

IROM : 253012 – code in flash (default or ICACHE_FLASH_ATTR)

IRAM : 28273 / 32768 – code in IRAM (IRAM_ATTR, ISRs…)

DATA : 1508 ) – initialized variables (global, static) in RAM/HEAP

RODATA : 2500 ) / 81920 – constants (global, static) in RAM/HEAP

BSS : 26776 ) – zeroed variables (global, static) in RAM/HEAP

Sketch uses 285293 bytes (29%) of program storage space. Maximum is 958448 bytes.

Global variables use 30784 bytes (37%) of dynamic memory, leaving 51136 bytes for local variables. Maximum is 81920 bytes.

esptool.py v3.0

Serial port COM3

Connecting……..…..…..…..…..…..….._____

Traceback (most recent call last):

File “C:\Users[user]\AppData\Local\Arduino15\packages\Dasduino_Boards\hardware\esp8266\1.0.0/tools/upload.py”, line 66, in

esptool.main(cmdline)

File “C:/Users/U­ENIK/AppData/Local/Arduino15/packages\Dasduino_Boards\hardware\esp8266\1.0.0/tools/esptool\esptool.py”, line 3552, in main

esp.connect(args.before, args.connect_attempts)

File “C:/Users/U­ENIK/AppData/Local/Arduino15/packages\Dasduino_Boards\hardware\esp8266\1.0.0/tools/esptool\esptool.py”, line 529, in connect

raise FatalError(‘Failed to connect to %s: %s’ % (self.CHIP_NAME, last_error))

esptool.FatalError: Failed to connect to ESP8266: Timed out waiting for packet header

Failed uploading: uploading error: exit status 1

My program:

#define BLYNK_PRINT Serial
#define BLYNK_TEMPLATE_ID "TeoZavrsni"
#define BLYNK_TEMPLATE_NAME "MeteoPostaja"
#include <BlynkSimpleEsp8266.h>
#include <BlynkTimer.h>
#include "DHTesp.h"

#ifdef ESP32
#pragma message(THIS EXAMPLE IS FOR ESP8266 ONLY!)
#error Select ESP8266 board.
#endif

int Sensor_PIN = 4; //D3
DHTesp dht;

char auth[] = "";
char ssid[] = "";
char pass[] = "";

float Temperature;
float Humidity;

BlynkTimer timer;

void myTimerEvent()
{
  Temperature = dht.getTemperature();
  Humidity = dht.getHumidity();
  Blynk.virtualWrite(V5, Temperature);
  Blynk.virtualWrite(V6, Humidity);
}

void setup()
{
  Serial.begin(9600);
  dht.setup(Sensor_PIN, DHTesp::DHT11);
  Blynk.begin(auth, ssid, pass);
  timer.setInterval(1000L, myTimerEvent);
}

void loop()
{
  Blynk.run();
  timer.run();
}
Original message (Croatian)

Poštovani došlo je do nekog malog progresa u mom projektu s obzirom na prošlo pitanje sada od Arduino IDE dobivam sljedeću poruku o grešci:

Executable segment sizes:

ICACHE : 32768 – flash instruction cache

IROM : 253012 – code in flash (default or ICACHE_FLASH_ATTR)

IRAM : 28273 / 32768 – code in IRAM (IRAM_ATTR, ISRs…)

DATA : 1508 ) – initialized variables (global, static) in RAM/HEAP

RODATA : 2500 ) / 81920 – constants (global, static) in RAM/HEAP

BSS : 26776 ) – zeroed variables (global, static) in RAM/HEAP

Sketch uses 285293 bytes (29%) of program storage space. Maximum is 958448 bytes.

Global variables use 30784 bytes (37%) of dynamic memory, leaving 51136 bytes for local variables. Maximum is 81920 bytes.

esptool.py v3.0

Serial port COM3

Connecting……..…..…..…..…..…..….._____

Traceback (most recent call last):

File “C:\Users[user]\AppData\Local\Arduino15\packages\Dasduino_Boards\hardware\esp8266\1.0.0/tools/upload.py”, line 66, in

esptool.main(cmdline)

File “C:/Users/U�ENIK/AppData/Local/Arduino15/packages/Dasduino_Boards/hardware/esp8266/1.0.0/tools/esptool\esptool.py”, line 3552, in main

esp.connect(args.before, args.connect_attempts)

File “C:/Users/U�ENIK/AppData/Local/Arduino15/packages/Dasduino_Boards/hardware/esp8266/1.0.0/tools/esptool\esptool.py”, line 529, in connect

raise FatalError(‘Failed to connect to %s: %s’ % (self.CHIP_NAME, last_error))

esptool.FatalError: Failed to connect to ESP8266: Timed out waiting for packet header

Failed uploading: uploading error: exit status 1

Moj program sad izgleda ovako:

#define BLYNK_PRINT Serial

#define BLYNK_TEMPLATE_ID “TeoZavrsni”

#define BLYNK_TEMPLATE_NAME “MeteoPostaja”

#include

#include

#include “DHTesp.h”

#ifdef ESP32

#pragma message(THIS EXAMPLE IS FOR ESP8266 ONLY!)

#error Select ESP8266 board.

#endif

int Sensor_PIN = 4; //D3

DHTesp dht;

// You should get Auth Token in the Blynk App.

// Go to the Project Settings (nut icon).

char auth = “”;

// Your WiFi credentials.

// Set password to “” for open networks.

char ssid = “”;

char pass = “”;

float Temperature;

float Humidity;

BlynkTimer timer;

// This function sends Arduino’s up time every second to Virtual Pin (5).

// In the app, Widget’s reading frequency should be set to PUSH. This means

// that you define how often to send data to Blynk App.

void myTimerEvent()

{

Temperature = dht.getTemperature(); // Gets the values of the temperature

Humidity = dht.getHumidity(); // Gets the values of the humidity

// You can send any value at any time.

// Please don’t send more that 10 values per second.

Blynk.virtualWrite(V5, Temperature);

Blynk.virtualWrite(V6, Humidity);

}

void setup()

{

// Debug console

Serial.begin(9600);

dht.setup(Sensor_PIN, DHTesp::DHT11);

Blynk.begin(auth, ssid, pass);

// You can also specify server:

//Blynk.begin(auth, ssid, pass, “blynk-cloud.com”, 80);

//Blynk.begin(auth, ssid, pass, IPAddress(192,168,1,100), 8080);

// Setup a function to be called every second

timer.setInterval(1000L, myTimerEvent);

}

void loop()

{

Blynk.run();

timer.run(); // Initiates BlynkTimer

}

Molim za pomoć

[name removed]

Originally submitted via email support on 30 April 2024. Migrated to the forum for community visibility.

Soldered Support:

Have you selected the correct COM port? You can identify which COM port is your Dasduino by connecting it, checking the available COM ports, then disconnecting it and checking the ports again to see which one disappeared.

Try using a newer board definition. Here is a tutorial on how to install the official ESP board definition: Installing ESP8266 in Arduino IDE (Windows, Mac OS X, Linux) | Random Nerd Tutorials

Try using ‘Generic ESP8266 Module’.

Also try a different USB port and cable if you have one available, as that’s always worth checking.

Try these things and we can see what happens next.

Original message (Croatian)

Pozdrav [name removed], odgovoriti ću ti na ovaj ticket jer vidim da ima napretka od prošlog, prošli ću zatvoriti.

Jesi li izabrao dobar COM port? Možeš vidjeti koji COM port ti je Dasduino tako što ga možeš spojiti, pogledati COM portove pa odspojiti i pogledati COM portove opet pa vidjeti koji fali.

Možeš probati koristiti novi board definition, ovdje je tutorial kako instalirati službeni ESP board definition: Installing ESP8266 in Arduino IDE (Windows, Mac OS X, Linux) | Random Nerd Tutorials

Probaj korsititi ‘Generic ESP8266 Module’.

Osim toga možeš probati različiti USB port i kabel ako imaš, to je uvijek dobra ideja.

Zasad probaj ove stvari pa ćemo vidjeti dalje.