Arduino Not Found on USB Ports

Hello!

I am trying to run this very simple sketch on my Arduino Nano in an effort to do a demo test to control a l293d motor driver. I may have shorted something momentarily, because now that same Arduino Nano cannot seem to be found on any of the USB Serial ports. Input 1 is connected to digital pin 3 of the Nano and input 2 is connected to pin 2.

Here is that code:

 void setup() {
  // put your setup code here, to run once:
Serial.begin(9600);
pinMode(2,OUTPUT);
pinMode(3,OUTPUT);
}

void loop() {
  // put your main code here, to run repeatedly:
digitalWrite(2,HIGH);
delay(500);
digitalWrite(2,LOW);
delay(500);
digitalWrite(3,HIGH);
delay(500);
digitalWrite(3,LOW);
delay(500);
}

The exact problem that is happening is that whenever I plug in (not upload a sketch to) the Arduino, a pop-up appears saying that the USB device is not recognised and that "it may have malfunctioned", though when I disconnected the motor driver and took the Arduino Nano out of the breadboard and tried plugging it back in, the onboard LEDs flashed as normal.

This is what the pop-up looks like:
Screenshot (91)

And this is the Arduino IDE error:

The sketch compiles correctly, but the computer seems like it cannot connect to this Arduino. In fact, when I hover over the "tools" dropdown in the Arduino IDE and look at "Ports", it is a gray color and I cannot click on it to change the port I am using.

However, I have also tried with a different Arduino Nano as well as an Arduino Mega; which both work fine just like a normal Arudino should. This is what makes me think that I just ruined my Arduino Nano.

Here is my wiring (the blue wires are the leads goint to the terminals of the motor):
WIN_20210709_17_15_13_Pro (2)

I really do not know what to do. I am currently working on a robotics project that requires these motor drivers for low current draw high accuracy motors, but it looks like I have burned up my only microcontroller that is currently not already in use for some other build...

Thank you to anyone who can help!

njmaas55

Are you able to upload to the Nano by itself after you take it out of the breadboard?

I was not able to upload anything to the Arduino Nano even after the board was disconnected for the motor driver and removed from the breadboard.

I have just now rewired the chip to work with the Arduino Mega.

This test was a success.

I still have to find out why my Arduino Nano cannot be found as a USB device.
Maybe I just have to keep this Nano on a shelf and buy some new ones.

I really do not want to have to do that, so really anything is helpful at this point.

Please provide a detailed description of what you mean by that.

None of the core wiring has changed. The same pins that were pulled to 5v are still pulled to 5v. Same for GND as well as the data and motor output pins. The wiring I have now is exactly the same, except for that I added longer jumper wires to the data and power wires so that it would be able to plug into the pin headers of the Arduino Mega.

Here is what it looks like now:

With the Nano stand-alone (not connected to anything), do you still get the message that the device malfunctioned when you connect it to the PC?

If not, what does Windows device manager say about your board? Does it show under ports?

Is there a difference between this specific Nano and the others? Check the chip underneath the board. Are the different (CH340 vs FTDI)?

When the Arduino is not connected to anything (breadboards, pin headers, etc.), the computer still shows the same pop-up and the IDE has the same error message.

What may be interesting to know is that if I try to upload the sketch with nothing connected, it gives me the same message as when I plugged in the faulty Arduino.

This makes me think that there is somehting going wrong between the IDE and the Microcontroller, leaving only one component: (like you said) the CH340.

Of course, leave it up to cheaper brands to not label their USB drivers...

When I turn over the Arduino to see the if the driver is a CH340 or FTDI chip, it is NOT LABLED.

Even when I hold it under the light, I cannot see any writing on it whatsoever. I have also checked with a family member and she also said that there was no writing visible.

The only component that is labled is the AMS1117, which is a voltage regulator from what I can see.

When I check the other Arduino Nano boards, they also do not have labeled USB drivers.

(Very frustrating, but I have an idea. It will take me a bit of time to explain, so i will write it in another reply. coming soon :slightly_smiling_face:)

The idea I had is this:

A few days ago, I was looking over the pinout of several different Arduino Boards and I noticed something that the Nano, Mega, and Uno shared: ICSP pins.

I wondered what these pins did, so I did some research and it turns out that they seems to be pins that you can program the microcontroller on. All you need is a working Arduino as the Programmer.

I have a working Arduino and my faulty Nano has ICSP pins.

What if I used the ICSP pins to program the Nano; hence bypassing the broken USB port and driver?

The reason why I was thinking this might work is because I have noticed that while the Nano cannot connect to the Serial ports on my computer, the "Power" LEDs still turn on; showing me that the problem may be either a corroded data line from the driver to the USB jack or the driver decided to give up and stop working.

Using the ICSP pins to program the Nano seems like a way to bypass the USB driver because ICSP seems to have the same data lines as SPI whereas USB seems to be related to UART in some way. Because SPI data interrpretation does not go though the broken driver, it is able to be programmed successfully!

I have really just started researching ICSP and I really don't know if those pins are even used to program Microcontrollers or if I actually did read the wiki page right...

I would really like to know your opinion before I try to upload something via ICSP.

Have you selected Nano in the type of Arduino menu? I ask because I've made that mistake many times...

As long as your PC has a problem with the board, the IDE can't do anything.

You might have a bad cable, the CH340 (if it's that one that is on the board) might be malfunctioning. Do you have a spare Nano for testing purposes?

You can upload sketches via ICSP. It will wipe the bootloader, not a big issue.

You will however not get your serial port back.

You can also buy a so-called FTDI cable or FTDI breakout board, connect it between the PC and the Nano and try to upload via that. Advantage, assuming it works, is that you have a serial port again.

1 Like

Yes. I dod not change which Arduino model I had been uploading to from when that same Nano was working.

Ok. In that case, I will upload via ICSP at the expense of the Serial ports.

Just one question: Does clearing the old bootloader and then burning a new one onto the Nano have a possibility of working?

One more thing to mention for @sterretje:
The only reason why I ask is because I found this:

The main part that caught my attention was, "It manages uploading and starting the sketches you make..."

I was wondering if burning a new bootloader would reset how it manages to upload new sketches, though I don't know how useful it would be if the computer does not even register the Arduino as a working USB device.

You can basically assume that the cheap Nano boards from China use the CH340.

The CH340 IC package in common use is different from that of the FT232R, so you can get a fairly good identification at a glance even without a label.

The FTDI FT232RL:

The CH340G:

If by "working", you mean will it solve the problem of the Nano no longer being recognized as a USB device, the answer is "No".

The reason is that the USB connection is handled by the CH340 chip. But you are burning the bootloader on the ATmega328P microcontroller; a completely different chip. So changing the bootloader or firmware on the ATmega328P will never have any effect on the USB CDC serial port generated by the CH340.

Thank you for the clarification on the CH340 chip (which looks a lot like the one this Nano uses).

So I guess burning a new bootloader to the microcontroller to fix a problem with a totally different USB driver won't work after all :slightly_smiling_face: .

Well, at least the USB jack wasn't the only way to program an Arduino (fortunately) even if it means losing the Serial port.

I will have to get a stand-alone FTDI breakout board just as an extra thing to have on hand when another cheap Arduino breaks.

I will be sure to click the "Solution" box on post #12 unless any of you want to add anything.

Thank you all so much for the help!

njmaas55

It's a useful tool to have even for purposes other than working with broken Arduino boards. I think you'll be glad to own one.

I do recommend you get one which uses the standard "FTDI header" pinout:

  • DTR or RTS
  • RX
  • TX
  • VCC
  • CTS
  • GND

That will allow you to plug the adapter right in to an Arduino Pro Mini, or many other boards that use this standard pinout. If you get an adapter with a non-standard pinout, you would need to use a mess of jumper wires to adapt it to the standard pinout. Some adapters don't even break out the DTR or RTS pin, without which you will need to manually reset the microcontroller at just the right time on every upload.

The adapter doesn't necessarily need to use an FTDI chip. That's just how the pinout configuration is referred to, since the FTDI FT232R was the most common chip in use at the time the phrase was coined. You can find adapters with CH340 or other chips that have the same pinout.

Glad to hear it!
I will definately get a breakout like the one you specified as I have been looking at the Arduino Pro Mini for a while now.