Every time I upload a sketch and disconnect my Arduino, I can't reconnect a second time. The PC is not seeing it for some reason. If I restart the PC, it comes right back and the whole issue repeats. If I reinstall the IDE, I can it to return as well, but the issue repeats again. Drivers are up to date. I tried uninstalling in device manager, but it won't reinstall/connect upon reconnecting. I have to restart. This happened to me on a completely different computer as well a year or two ago. Any ideas?
Do you have any other devices connected to the computer's USB ports? Does the problem persist if you disconnect all other USB devices?
Yes, I have quite a few...keyboard, mouse, camera and an HDD. I am plugging the Arduino directly into the back of the PC. No hubs. In device manager, it says the majority of the ports are free. Including COM3, which is what the PC grabbed for the Arduino. I'll try unplugging everything....
Yes, I just unplugged everything, then plugged the Arduino in....it picked right up. I unplugged it again and plugged it back....it did not connect. I plugged all my USB devices back in and tried the Arduino again....it worked. I plugged it back in yet again....it does not work. I've never had so much trouble with a USB device...lol. Makes it very difficult to work with these devices.
Hm, and do you have the same behavior with any other USB device? For instance, if you plug in the HDD, unplug it, and immediately plug it back in, does it also malfunction?
It sounds like a problem in the USB driver stack of your machine. You mention the drivers are up to date, but is this also true for the drivers that associate with the chipset on your motherboard? For instance, if you use a motherboard with an Intel chipset, you'll find Intel publishes driver packs that control all sorts of peripherals - these drivers often solve issues with the 'native' Windows drivers (even though they appear to work, there can be bugs).
Nope, never had a single issue. It is ONLY the Arduinos. Pretty sure all my drivers are up to date. However, I will check again. Also, this isn't the only PC this has happened to me on.
All Arduinos give the same issue? Which ones have you tried?
Okay I think I figured it out. If I pull the Arduino out of the breadboard....seems to work no problem on multiple connects/disconnects. I put it back into the breadboard....doesn't work. I pull all jumpers and narrow it down to the Vin. If the Vin is connected to the power rail I run into the issue. As soon as I pull the jumper to Vin....it connects no problem. Could power from the USB be sending power through the Vin to the power rail, interfering with some other component and causing the issue? All I have connected is a DFPlayer Mini at the moment. Regardless, I know what I need to do to prevent the issue now. Might be a problem when it's all soldered together though...lol.
What sketch?
Which Arduino?
I found the cause, well close enough to it anyway. See my post above. It has something to do with the Vin being connected to the powerrail on my breadboard when connected via USB. As soon as I pull the jumper...it connects/disconnects without any issues. It is an Nano Every.
Then you have found a symptom of the problem.
Please post a good diagram, even if you have to hand draw it, and some of these talented users (probably not me) will help you find and understand the actual problem.
That's right; your PC will probably freak out because it 'sees' 5V being fed into the USB port, causing the motherboard to actually shut down the USB port. Count yourself lucky, this has saved your computer.
DON'T connect a power supply to Vin and simultaneously connect the USB cable.
The power supply was never connected…only usb. I know well enough not to connect both .
There's part of the issue.
I've seen that guy's work before and even spoken to him by email a few times.
He makes mistakes, small ones.
That miniplayer does 2 or 3 watts and it should not be powered directly by the Arduino.
So, by supplying the power by USB then it's going through the board and to the rail, thence to the player.
I'm not sure about all that.
Also, the two yellow wires, they run to another power supply?
I also believe that your resistors might be incorrectly installed, unless I can't see the pins at an angle or something.
I think you need to draw a schematic of what you actually have wired and not refer to the tutorial drawing when doing so. These other guys are way better at this than I am but I know for them to help that they will need a clear schematic, even a hand drawn one.
This doesn’t make much sense, VIN is designed to be used together with USB power or separately. VIN is not connected to USB directly, +5V is but through the diode and in such way that it cannot interfere with USB
My bad, you're right.
Btw, it would have helped IMO if it were clear from the start that OP is apparently using a Nano Every.
Nah, it should work with this combination of parts. But an easy test is to remove the connections to the MP3 player and see if the problem persists. Better yet - just connect the Nano board without anything attached to it at all.
That would definitely be very useful!
For that Arduino because it can put out a bit more on the 5V pin. 800 mA is high for most onboard regulators though, isn't it?
My point being it will work for his Arduino but is still a bad practice for the next guy who wants to do the same thing with an Uno.
I just run Rx through a 10k to the pin. I don't understand the config in the tutorial.
But op is not using 5v pin at all, that rail connection is to the board not from it
Yeah, it uses a buck regulator that will go up to 1.2A apparently. As long as Vin is close to Vout it will be fairly efficient.
HOWEVER - the buck regulator is only used to make 5V from the higher Vin. It plays no role when the device is connected to USB. With a USB port, there may of course be a protection on the mainboard/PC-side that switches off USB functionality if the current draw exceeds a safety limit. Officially that's 500mA, but most mainboards will supply significantly more. 800mA may or may not be too much.
His comment 12 is to the contrary .