Problem with IDE or libraries Edit: with board or connector

@ptillisch no still same error, btw is it possible that due to the lcd that my arduino is connected to?

It certainly could be.

Disconnect the LCD as well as all other external circuitry/shields/modules/etc. from the board and then try uploading again. If the upload is successful when you don't have anything connected to the board, then you will know that the failure was caused by the circuitry and we can then focus our efforts on solving the problem with the circuitry.

1 Like

@ptillisch there is still problem, I soldered out the pins from nano and still same avrdude problem

Given the information gathered so far, I am left with only two possible causes for the upload failure:

  • The bootloader was somehow corrupted.
  • There is physical damage to the microcontroller or its support circuitry.

Even though the blinking LED after you press the reset button does indicate the bootloader is at least somewhat functional, there is still a possibility that it was corrupted in a way that leaves it able to blink the LED, but not to perform an upload. If so, the board might be recoverable by performing a "Burn Bootloader" operation.

I have to warn you there is no guarantee that this somewhat complex procedure which requires additional hardware will recover your board. But if you have the necessary hardware and are up for a challenge and an interesting project then I think it is worth a try.

Prepare ISP programmer

You will need an ISP programmer. If you don't have a programmer, you can use a spare Arduino board as an "Arduino as ISP" programmer.

Arduino as ISP

The following instructions are for using an Arduino board as an "Arduino as ISP" programmer. If you have a dedicated programmer, you can skip to the next set of instructions.

Although the "Arduino as ISP" only works for programming targets of the AVR architecture, you can also use boards of a variety of architectures (e.g., "AVR", "SAMD", "megaAVR") as an "Arduino as ISP" programmer.


In the instructions below, the board used as an "Arduino as ISP" is referred to as the "programmer board". The board the bootloader is being burned on is referred to as the "target board".


  1. Disconnect the USB cable of the Arduino boards from your computer.

  2. Make the following connections between the "programmer board" and the "target board".

    Programmer Target
    CIPO (AKA "MISO") CIPO
    VCC 5V (VCC on 3.3 V boards)
    SCK SCK
    COPI (AKA "MOSI") COPI
    10 RESET
    GND GND

    The documentation for the boards you are using will identify the location of these pins. If you are using an official Arduino board, check the pinout diagram on the documentation page for the board.

  3. Connect the "programmer board" to your computer with a USB cable.

  4. Select File > Examples > 11.ArduinoISP > ArduinoISP from the Arduino IDE menus.
    The "ArduinoISP" sketch will open in Arduino IDE.

  5. Select your "programmer board" from Arduino IDE's Tools > Board menu.

  6. Select the port of your "programmer board" from Arduino IDE's Tools > Port menu.

  7. Select Sketch > Upload from the Arduino IDE menus.

  8. Wait for the upload to finish.

You are now ready to burn the bootloader using your "Arduino as ISP" programmer.

Burn Bootloader

Instructions for burning the bootloader:

It is not possible to do this via Arduino Cloud Editor. You will need to use Arduino IDE or Arduino CLI.

  1. Connect an ISP programmer to your Arduino board.
    If you are using an "Arduino as ISP", then you have already connected it according to the previous instructions.
  2. Select the target board from the Tools > Board menu and any other custom Tools menus (e.g., Tools > Processor).
  3. Select the appropriate programmer from the Tools > Programmer menu.
  4. Tools > Burn Bootloader
  5. Wait for the process to finish successfully.
  6. Disconnect the USB cable of the programmer from your computer.
  7. Disconnect the programmer from the "target board".

Now connect the "target board" to your computer with a USB cable, select its port from the Tools > Port menu, and try uploading a sketch as usual.

Conclusion

Now connect the "target board" to your computer with a USB cable and try uploading again. Does the upload succeed now?

@ptillisch again same avrdude error

Was the "Burn Bootloader" operation successful?

@ptillisch NO same "programmer not responding"

Please tell me the exact step in the instructions I provided at which you encountered the error.

Are you attempting to use the other nonfunctional Nano board as the "programmer board", or do you have a functional board you can use as the programmer?

I encountered error at burn bootloader which gave the same
"programmer not responding"

I do not understand 2nd question

As a side note: Original sketch had a pump, a relay on pin 8 and a device on pin 7 (analogWrite(7, con). Knowing how the pump and relay were connected, and what device was on pin 7 might give clues to the USB issue.

7 is for lcd contrast to VEE

Contrast adjust? That is usually connected to a potentiometer.

The instructions are for you to have two Arduino boards to do this programming.

  1. Arduino board #1 is configured as ISP (In-System-Programmer)
  2. Arduino board #2 is the Target Board (to be programmed by the ISP)

Your "good" board (blinking LED) was to be the ISP.
Your "bad" board (not blinking LED) was to be the Target Board.

I believe board #1 (ISP) is an entirely different board that can be uploaded to.
Board #2 (target) is the Nano that blinks but still errors.

Bad board is still in a drawer.

1 Like

@evanmars No both are nano

@xfpd do I need two cables for that?

Follow the instructions in post #24.

@evanmars @xfpd @ptillisch guys tell me do i need two nanos

Seems pretty obvious that two boards are needed. The ISP doesn't have to be a Nano.

but i dont have two wires @evanmars