Arduino UNO + Wifi + R3 + ATMega328P + ESP8266 CH340: Upload Sketch

Hi all,
I have an Arduino UNO + Wifi + R3 + ATMega328P.
I am triyng to upload some simple sketch but I always receive errors after upload.
I think I am not selecting properly the board in the Arduino IDE software. Please can someone advise ?

Thanks in advance.
Carlos.

Please do this:

  • (In the Arduino IDE) File > Preferences
  • Uncheck the checkbox next to “Show verbose output during: compilation”
  • Check the checkbox next to "Show verbose output during: upload
  • Click “OK”
  • Sketch > Upload
  • After the upload fails, you’ll see a button on the right side of the orange bar “Copy error messages” (or the icon that looks like two pieces of paper at the top right corner of the black console window in the Arduino Web Editor). Click that button.
  • In a forum reply here, click on the reply field.
  • Click the </> button on the forum toolbar. This will add the forum’s code tags markup to your reply.
  • Press “Ctrl + V”. This will paste the upload output between the code tags.
  • Move the cursor outside of the code tags before you add any additional text to your reply.

Please provide more information about this Arduino UNO + Wifi + R3 + ATMega328P. I’m not familiar with this.

Is this one of those boards with the DIP switches?
Not straight forward to use.

READ ---> https://forum.arduino.cc/index.php?topic=590290.0

.

Arduino:1.8.13 (Windows 10), Tarjeta:"Arduino Uno"

El Sketch usa 1486 bytes (4%) del espacio de almacenamiento de programa. El máximo es 32256 bytes.

Las variables Globales usan 200 bytes (9%) de la memoria dinámica, dejando 1848 bytes para las variables locales. El máximo es 2048 bytes.

C:\Users\usuario\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/bin/avrdude -CC:\Users\usuario\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf -v -patmega328p -carduino -PCOM5 -b115200 -D -Uflash:w:C:\Users\usuario\AppData\Local\Temp\arduino_build_738630/sketch_mar11a.ino.hex:i 



avrdude: Version 6.3-20190619

         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/

         Copyright (c) 2007-2014 Joerg Wunsch



         System wide configuration file is "C:\Users\usuario\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf"



         Using Port                    : COM5

         Using Programmer              : arduino

         Overriding Baud Rate          : 115200

         AVR Part                      : ATmega328P

         Chip Erase delay              : 9000 us

         PAGEL                         : PD7

         BS2                           : PC2

         RESET disposition             : dedicated

         RETRY pulse                   : SCK

         serial program mode           : yes

         parallel program mode         : yes

         Timeout                       : 200

         StabDelay                     : 100

         CmdexeDelay                   : 25

         SyncLoops                     : 32

         ByteDelay                     : 0

         PollIndex                     : 3

         PollValue                     : 0x53

         Memory Detail                 :



                                  Block Poll               Page                       Polled

           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack

           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------

           eeprom        65    20     4    0 no       1024    4      0  3600  3600 0xff 0xff

           flash         65     6   128    0 yes     32768  128    256  4500  4500 0xff 0xff

           lfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00

           hfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00

           efuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00

           lock           0     0     0    0 no          1    0      0  4500  4500 0x00 0x00

           calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00

           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00



         Programmer Type : Arduino

         Description     : Arduino

         Hardware Version: 3

         Firmware Version: 4.4

         Vtarget         : 0.3 V

         Varef           : 0.3 V

         Oscillator      : 1.176 kHz

         SCK period      : 3.3 us



avrdude: AVR device initialized and ready to accept instructions



Reading | ################################################## | 100% 0.00s



avrdude: Device signature = 0x1e950f (probably m328p)

avrdude: reading input file "C:\Users\usuario\AppData\Local\Temp\arduino_build_738630/sketch_mar11a.ino.hex"

avrdude: writing flash (1486 bytes):



Writing | ################################################## | 100% 0.27s



avrdude: 1486 bytes of flash written

avrdude: verifying flash memory against C:\Users\usuario\AppData\Local\Temp\arduino_build_738630/sketch_mar11a.ino.hex:

avrdude: load data flash data from input file C:\Users\usuario\AppData\Local\Temp\arduino_build_738630/sketch_mar11a.ino.hex:

avrdude: input file C:\Users\usuario\AppData\Local\Temp\arduino_build_738630/sketch_mar11a.ino.hex contains 1486 bytes

avrdude: reading on-chip flash data:



Reading | #########################

avrdude: stk500_paged_load(): (a) protocol error, expect=0x10, resp=0x00

avrdude: stk500_paged_load(): (a) protocol error, expect=0x10, resp=0x00



####avrdude: stk500_cmd(): programmer is out of sync

avr_read(): error reading address 0x0000

    read operation not supported for memory "flash"

avrdude: failed to read all of flash memory, rc=-2

avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x00



avrdude done.  Thank you.





Este informe podría contener más información con
"Mostrar salida detallada durante la compilación"
opción habilitada en Archivo -> Preferencias.

Hi everyone,
first of all, thanks for your answer.
I have followed the instructions indicated and above you can see the error messages received triyng to upload a simple sketch ("Hello Word").
Below you can see the configuration I am using:

  • Board: Arduino UNO + Wifi + R3 + ATMega328P + ESP8266 CH340 with DIP switches.
  • Arduino IDE configuration: Board Arduino UNO
  • DIP Switches configuration: 1OFF, 2OFF, 3ON, 4ON, 5OFF, 6OFF, 7OFF, 8OFF

Thanks in advance for your help.
Carlos.

cdmmez:
Below you can see the configuration I am using:

  • Board: Arduino UNO + Wifi + R3 + ATMega328P + ESP8266 CH340 with DIP switches.

Huh? I would need to see a schematic or block diagram to make sense of this.

SteveMann:
Huh? I would need to see a schematic or block diagram to make sense of this.

There is no schematic.

It is a board made by Robotdyn. I linked it above.

cdmmez:

Arduino:1.8.13 (Windows 10), Tarjeta:"Arduino Uno"

El Sketch usa 1486 bytes (4%) del espacio de almacenamiento de programa. El máximo es 32256 bytes.

Las variables Globales usan 200 bytes (9%) de la memoria dinámica, dejando 1848 bytes para las variables locales. El máximo es 2048 bytes.

C:\Users\usuario\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/bin/avrdude -CC:\Users\usuario\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf -v -patmega328p -carduino -PCOM5 -b115200 -D -Uflash:w:C:\Users\usuario\AppData\Local\Temp\arduino_build_738630/sketch_mar11a.ino.hex:i

avrdude: Version 6.3-20190619

Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/

Copyright (c) 2007-2014 Joerg Wunsch

System wide configuration file is "C:\Users\usuario\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf"

Using Port                    : COM5

Using Programmer              : arduino

Overriding Baud Rate          : 115200

AVR Part                      : ATmega328P

Chip Erase delay              : 9000 us

PAGEL                        : PD7

BS2                          : PC2

RESET disposition            : dedicated

RETRY pulse                  : SCK

serial program mode          : yes

parallel program mode        : yes

Timeout                      : 200

StabDelay                    : 100

CmdexeDelay                  : 25

SyncLoops                    : 32

ByteDelay                    : 0

PollIndex                    : 3

PollValue                    : 0x53

Memory Detail                :

Block Poll              Page                      Polled

Memory Type Mode Delay Size  Indx Paged  Size  Size #Pages MinW  MaxW  ReadBack

----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------

eeprom        65    20    4    0 no      1024    4      0  3600  3600 0xff 0xff

flash        65    6  128    0 yes    32768  128    256  4500  4500 0xff 0xff

lfuse          0    0    0    0 no          1    0      0  4500  4500 0x00 0x00

hfuse          0    0    0    0 no          1    0      0  4500  4500 0x00 0x00

efuse          0    0    0    0 no          1    0      0  4500  4500 0x00 0x00

lock          0    0    0    0 no          1    0      0  4500  4500 0x00 0x00

calibration    0    0    0    0 no          1    0      0    0    0 0x00 0x00

signature      0    0    0    0 no          3    0      0    0    0 0x00 0x00

Programmer Type : Arduino

Description    : Arduino

Hardware Version: 3

Firmware Version: 4.4

Vtarget        : 0.3 V

Varef          : 0.3 V

Oscillator      : 1.176 kHz

SCK period      : 3.3 us

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.00s

avrdude: Device signature = 0x1e950f (probably m328p)

avrdude: reading input file "C:\Users\usuario\AppData\Local\Temp\arduino_build_738630/sketch_mar11a.ino.hex"

avrdude: writing flash (1486 bytes):

Writing | ################################################## | 100% 0.27s

avrdude: 1486 bytes of flash written

avrdude: verifying flash memory against C:\Users\usuario\AppData\Local\Temp\arduino_build_738630/sketch_mar11a.ino.hex:

avrdude: load data flash data from input file C:\Users\usuario\AppData\Local\Temp\arduino_build_738630/sketch_mar11a.ino.hex:

avrdude: input file C:\Users\usuario\AppData\Local\Temp\arduino_build_738630/sketch_mar11a.ino.hex contains 1486 bytes

avrdude: reading on-chip flash data:

Reading | #########################

avrdude: stk500_paged_load(): (a) protocol error, expect=0x10, resp=0x00

avrdude: stk500_paged_load(): (a) protocol error, expect=0x10, resp=0x00

####avrdude: stk500_cmd(): programmer is out of sync

avr_read(): error reading address 0x0000

read operation not supported for memory "flash"

avrdude: failed to read all of flash memory, rc=-2

avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x00

avrdude done.  Thank you.

Este informe podría contener más información con
"Mostrar salida detallada durante la compilación"
opción habilitada en Archivo -> Preferencias.




Hi everyone,
first of all, thanks for your answer.
I have followed the instructions indicated and above you can see the error messages received triyng to upload a simple sketch ("Hello Word").
Below you can see the configuration I am using:

- Board: Arduino UNO + Wifi + R3 + ATMega328P + ESP8266 CH340 with DIP switches.
- Arduino IDE configuration: Board Arduino UNO
- DIP Switches configuration: 1OFF, 2OFF, 3ON, 4ON, 5OFF, 6OFF, 7OFF, 8OFF

Thanks in advance for your help.
Carlos.

I am guessing that the "Hello World" sketch prints to the Serial Monitor?

Do you have another board to try?

.

/* Comment this out to disable prints and save space */
#define BLYNK_PRINT Serial


#include <ESP8266_Lib.h>
#include <BlynkSimpleShieldEsp8266.h>

// You should get Auth Token in the Blynk App.
// Go to the Project Settings (nut icon).
char auth[] = "I1SMrSaKeYD1PwAPcJhBcGpuAqOXlAOz";

// Your WiFi credentials.
// Set password to "" for open networks.
char ssid[] = "YourNetworkName";
char pass[] = "YourPassword";

// Hardware Serial on Mega, Leonardo, Micro...
//#define EspSerial Serial1

// or Software Serial on Uno, Nano...
#include <SoftwareSerial.h>
SoftwareSerial EspSerial(2, 3); // RX, TX

// Your ESP8266 baud rate:
#define ESP8266_BAUD 115200

ESP8266 wifi(&EspSerial);

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()
{
  // You can send any value at any time.
  // Please don't send more that 10 values per second.
  Blynk.virtualWrite(V5, millis() / 1000);
}

void setup()
{
  // Debug console
  Serial.begin(9600);

  // Set ESP8266 baud rate
  EspSerial.begin(ESP8266_BAUD);
  delay(10);

  Blynk.begin(auth, wifi, ssid, pass);
  // You can also specify server:
  //Blynk.begin(auth, wifi, ssid, pass, "blynk-cloud.com", 80);
  //Blynk.begin(auth, wifi, 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
}

Hi all, finally I could upload the “Hello Word” sketch.
Now I am in the next step, it means, try to work with the embedded wifi ESP8266 module.
I can send AT commands to the ESP8266 without problems, in fact, the module is connected to the wifi.
But when I try to upload the above sketch to use arduino with blynk app I receive the below error messages. Please advise:

Arduino:1.8.13 (Windows 10), Tarjeta:"Arduino Uno"

El Sketch usa 17866 bytes (55%) del espacio de almacenamiento de programa. El máximo es 32256 bytes.

Las variables Globales usan 1133 bytes (55%) de la memoria dinámica, dejando 915 bytes para las variables locales. El máximo es 2048 bytes.

C:\Users\usuario\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/bin/avrdude -CC:\Users\usuario\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf -v -patmega328p -carduino -PCOM6 -b115200 -D -Uflash:w:C:\Users\usuario\AppData\Local\Temp\arduino_build_892006/Arduino_WiFi_Shield.ino.hex:i 



avrdude: Version 6.3-20190619

         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/

         Copyright (c) 2007-2014 Joerg Wunsch



         System wide configuration file is "C:\Users\usuario\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf"



         Using Port                    : COM6

         Using Programmer              : arduino

         Overriding Baud Rate          : 115200

         AVR Part                      : ATmega328P

         Chip Erase delay              : 9000 us

         PAGEL                         : PD7

         BS2                           : PC2

         RESET disposition             : dedicated

         RETRY pulse                   : SCK

         serial program mode           : yes

         parallel program mode         : yes

         Timeout                       : 200

         StabDelay                     : 100

         CmdexeDelay                   : 25

         SyncLoops                     : 32

         ByteDelay                     : 0

         PollIndex                     : 3

         PollValue                     : 0x53

         Memory Detail                 :



                                  Block Poll               Page                       Polled

           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack

           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------

           eeprom        65    20     4    0 no       1024    4      0  3600  3600 0xff 0xff

           flash         65     6   128    0 yes     32768  128    256  4500  4500 0xff 0xff

           lfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00

           hfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00

           efuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00

           lock           0     0     0    0 no          1    0      0  4500  4500 0x00 0x00

           calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00

           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00



         Programmer Type : Arduino

         Description     : Arduino

         Hardware Version: 3

         Firmware Version: 4.4

         Vtarget         : 0.3 V

         Varef           : 0.3 V

         Oscillator      : 28.800 kHz

         SCK period      : 3.3 us



avrdude: AVR device initialized and ready to accept instructions



Reading | ################################################## | 100% 0.00s



avrdude: Device signature = 0x1e950f (probably m328p)

avrdude: reading input file "C:\Users\usuario\AppData\Local\Temp\arduino_build_892006/Arduino_WiFi_Shield.ino.hex"

avrdude: writing flash (17866 bytes):



Writing | ###########################avrdude: loadaddr(): (b) protocol error, expect=0x14, resp=0xfc

######avrdude: loadaddr(): (b) protocol error, expect=0x14, resp=0xfc

#######avrdude: stk500_loadaddr(): (a) protocol error, expect=0x14, resp=0x10

########## | 100% 3.17s



avrdude: 17866 bytes of flash written

avrdude: verifying flash memory against C:\Users\usuario\AppData\Local\Temp\arduino_build_892006/Arduino_WiFi_Shield.ino.hex:

avrdude: load data flash data from input file C:\Users\usuario\AppData\Local\Temp\arduino_build_892006/Arduino_WiFi_Shield.ino.hex:

avrdude: input file C:\Users\usuario\AppData\Local\Temp\arduino_build_892006/Arduino_WiFi_Shield.ino.hex contains 17866 bytes

avrdude: reading on-chip flash data:



Reading | ###

el puerto seleccionado 

 no existe o tu placa no esta conectada

avrdude: stk500_paged_load(): (a) protocol error, expect=0x10, resp=0x00

avrdude: stk500_cmd(): programmer is out of sync

avr_read(): error reading address 0x0000

    read operation not supported for memory "flash"

avrdude: failed to read all of flash memory, rc=-2

avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x00



avrdude done.  Thank you.





Este informe podría contener más información con
"Mostrar salida detallada durante la compilación"
opción habilitada en Archivo -> Preferencias.

Hi all,

I am not sure if I am selecting the correct board in the Arduino IDE.
The question is that I can upload the below "Hello Word" simple skecth and see the results in the serial monitor, but I receive some errors uploading the sketch (see at the end of this post):

Code:
void setup()
{
// Debug console
Serial.begin(9600);
Serial.println("Hello World");
}

void loop()
{
// Blynk.run();
}

Error:

Arduino:1.8.13 (Windows 10), Tarjeta:"Arduino Uno"

El Sketch usa 1486 bytes (4%) del espacio de almacenamiento de programa. El máximo es 32256 bytes.

Las variables Globales usan 200 bytes (9%) de la memoria dinámica, dejando 1848 bytes para las variables locales. El máximo es 2048 bytes.

C:\Users\usuario\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/bin/avrdude -CC:\Users\usuario\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf -v -patmega328p -carduino -PCOM6 -b115200 -D -Uflash:w:C:\Users\usuario\AppData\Local\Temp\arduino_build_933125/Arduino_org_UNO_WiFi.ino.hex:i 



avrdude: Version 6.3-20190619

         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/

         Copyright (c) 2007-2014 Joerg Wunsch



         System wide configuration file is "C:\Users\usuario\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf"



         Using Port                    : COM6

         Using Programmer              : arduino

         Overriding Baud Rate          : 115200

         AVR Part                      : ATmega328P

         Chip Erase delay              : 9000 us

         PAGEL                         : PD7

         BS2                           : PC2

         RESET disposition             : dedicated

         RETRY pulse                   : SCK

         serial program mode           : yes

         parallel program mode         : yes

         Timeout                       : 200

         StabDelay                     : 100

         CmdexeDelay                   : 25

         SyncLoops                     : 32

         ByteDelay                     : 0

         PollIndex                     : 3

         PollValue                     : 0x53

         Memory Detail                 :



                                  Block Poll               Page                       Polled

           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack

           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------

           eeprom        65    20     4    0 no       1024    4      0  3600  3600 0xff 0xff

           flash         65     6   128    0 yes     32768  128    256  4500  4500 0xff 0xff

           lfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00

           hfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00

           efuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00

           lock           0     0     0    0 no          1    0      0  4500  4500 0x00 0x00

           calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00

           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00



         Programmer Type : Arduino

         Description     : Arduino

         Hardware Version: 3

         Firmware Version: 4.4

         Vtarget         : 0.3 V

         Varef           : 0.3 V

         Oscillator      : 1.176 kHz

         SCK period      : 3.3 us



avrdude: AVR device initialized and ready to accept instructions



Reading | ################################################## | 100% 0.01s



avrdude: Device signature = 0x1e950f (probably m328p)

avrdude: reading input file "C:\Users\usuario\AppData\Local\Temp\arduino_build_933125/Arduino_org_UNO_WiFi.ino.hex"

avrdude: writing flash (1486 bytes):



Writing | ################################################## | 100% 0.27s



avrdude: 1486 bytes of flash written

avrdude: verifying flash memory against C:\Users\usuario\AppData\Local\Temp\arduino_build_933125/Arduino_org_UNO_WiFi.ino.hex:

avrdude: load data flash data from input file C:\Users\usuario\AppData\Local\Temp\arduino_build_933125/Arduino_org_UNO_WiFi.ino.hex:

avrdude: input file C:\Users\usuario\AppData\Local\Temp\arduino_build_933125/Arduino_org_UNO_WiFi.ino.hex contains 1486 bytes

avrdude: reading on-chip flash data:



Reading | 

Ha ocurrido un error mientras se enviaba el sketch

avrdude: stk500_paged_load(): (a) protocol error, expect=0x10, resp=0x00

####avrdude: stk500_cmd(): programmer is out of sync

avr_read(): error reading address 0x0000

    read operation not supported for memory "flash"

avrdude: failed to read all of flash memory, rc=-2

avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x00



avrdude done.  Thank you.





Este informe podría contener más información con
"Mostrar salida detallada durante la compilación"
opción habilitada en Archivo -> Preferencias.

I don't have this board.

Try putting the Serial.println("hello world"); inside loop() and put a delay(1000);.