# Uploading not working on computer with arduino mega

**URL:** <https://forum.arduino.cc/t/uploading-not-working-on-computer-with-arduino-mega/1058832>\
**Category:** IDE 1.x\
**Created:** [November 28, 2022, 5:28am UTC](https://forum.arduino.cc/t/uploading-not-working-on-computer-with-arduino-mega/1058832 "2022-11-28T05:28:05Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![pixelator11](https://avatars.discourse-cdn.com/v4/letter/p/cab0a1/32.png) [@pixelator11](https://forum.arduino.cc/u/pixelator11)\
**Post date:** [November 28, 2022, 5:28am UTC](https://forum.arduino.cc/t/uploading-not-working-on-computer-with-arduino-mega/1058832/1 "2022-11-28T05:28:05Z")

</div>

The Arduino code I use is verified and all correct but the uploading just keeps repeating a error message.

```cpp
Sketch uses 6850 bytes (2%) of program storage space. Maximum is 253952 bytes.
Global variables use 493 bytes (6%) of dynamic memory, leaving 7699 bytes for local variables. Maximum is 8192 bytes.
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
Failed uploading: uploading error: exit status 1

```

 ![Screenshot 2022-11-27 at 9.24.59 PM](https://europe1.discourse-cdn.com/arduino/original/4X/0/0/7/0074c51988f5890891eec539104cce8ca89a5373.jpeg)

---

<div class="post-metadata">

**Author:** ![Grumpy\_Mike](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/grumpy_mike/32/213521_2.png) [@Grumpy\_Mike](https://forum.arduino.cc/u/Grumpy_Mike)\
**Post date:** [November 28, 2022, 5:40am UTC](https://forum.arduino.cc/t/uploading-not-working-on-computer-with-arduino-mega/1058832/2 "2022-11-28T05:40:11Z")

</div>

> [@pixelator11](#):
>
> `avrdude: stk500v2_ReceiveMessage(): timeout`

This means that the Arduino can't contact your board.

Normally this is caused by not selection the correct board in the tools menu. Note for a mega there is a processor type that needs to be set to the type you have.

It can also be caused by a faulty Mega or USB lead.

This is nothing to do with the code you are trying to upload.

---

<div class="post-metadata">

**Author:** ![sterretje](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/sterretje/32/391294_2.png) [@sterretje](https://forum.arduino.cc/u/sterretje)\
**Post date:** [November 28, 2022, 7:52am UTC](https://forum.arduino.cc/t/uploading-not-working-on-computer-with-arduino-mega/1058832/3 "2022-11-28T07:52:40Z")

</div>

Adding to @Grumpy_Mike's reply, does your port _`/dev/cu.Bluetooth-Incoming-Port`_ disappear if you disconnect the Mega? If not, it's not your Mega.

---

<div class="post-metadata">

**Author:** ![johnwasser](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/johnwasser/32/214270_2.png) [@johnwasser](https://forum.arduino.cc/u/johnwasser)\
**Post date:** [November 28, 2022, 8:42pm UTC](https://forum.arduino.cc/t/uploading-not-working-on-computer-with-arduino-mega/1058832/4 "2022-11-28T20:42:28Z")

</div>

Definitely the wrong port.

If the correct port is not showing up (something like "/dev/cu.usbmodem142301") you may need to install drivers for the USB-to-Serial chip on your Mega.

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/system/32/1140315_2.png) [@system](https://forum.arduino.cc/u/system)\
**Post date:** [May 27, 2023, 8:42pm UTC](https://forum.arduino.cc/t/uploading-not-working-on-computer-with-arduino-mega/1058832/5 "2023-05-27T20:42:53Z")

</div>

Closed on May 27, 2023, 8:42pm UTC

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.
