I have purchased an ARD Mega2560R3 Board and I wanted to program it using Arduino SW 1.8.19.
Unfortunately, it does not work, I get this error message:
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\user\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf"
Using Port : COM3
Using Programmer : wiring
Overriding Baud Rate : 115200
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_getsync(): timeout communicating with programmer
avrdude done. Thank you.
An error occurred while uploading the sketch
On the board there are two LEDs, one of them is on continuously, the other one flashes intermittently, ~500ms on, ~250ms off.
The COM3 port is available, but is listed in Arduino as "Electrow CrowPanel 7.0P" (strange), and I do not receive any data on it (I tried all Baudrates).
Does the port disappear when you disconnect the board? If not, you have the wrong port selected.
Else, the Elecrow board uses the CH340 serial-to-usb converter. Based on that
You have also installed the ESP32 board package (not relevant).
Your Mega uses the CH340.
Is the print on that IC readable? It's the IC closest to the USB port. You might have to fiddle a little with the light and take a photo that you can enlarge to read it.
The COM3 disappears when the USB cable is removed.
The CH430G device is visible.
However, after a closer look at the board, it seems that it is different from the latest "official" Joy-it board:
The small TX LED is flashing shortly when something is transmitted over serial, also when upload starts, and after each timeout (when another try is triggered I suppose) but nothing more happens
No difference between the first flash and the sequence? I have a vague memory that the sequence that you describe happens when no sketch is loaded but don't pin me on that.
Usually boards come pre-loaded with the blink sketch (one second on, one second off). If your board did not do that from the start (when you bought it), you possibly have a broken board.
I have the feeling that the TX,RX pins from CH340G go directly to the AtMega MCU, and one need something in between to program the code.
On the genuine Arduino Mega boards there is another AVR IC which programs the transmitted code, isn't it?
EDIT
Or maybe I need to program a bootloader first?
The 16U2 on official boards serves the same purpose as the CH340. Neither of them is usually directly connected to the 2560 but through series resistors. No extra steps / things are needed when using tge CH340.
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\user\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf"
Using Port : usb
Using Programmer : stk500v2
avrdude: usbdev_open(): did not find any USB device "usb" (0x03eb:0x2104)
avrdude done. Thank you.
Error while burning bootloader.
But the mega board is connected via USB...
Should I put the AtMega2560 in a special state in order to work? How do I do that?