Go Down

Topic: Windows 10 stopped showing arduino in device manager (Read 345 times) previous topic - next topic

noindyfikator

Aug 28, 2017, 07:34 pm Last Edit: Aug 28, 2017, 08:00 pm by noindyfikator
Hello everybody...
1. Sorry for my bad english

I bought arduino 3 days ago. Everything was working correctly.
Since today. I just made project with RGB. From this website: https://learn.adafruit.com/adafruit-arduino-lesson-3-rgb-leds/arduino-sketch

I tried to change code. I changed method setColor to:

void setColor(int red, int green, int blue)
{
for(int i = 0; i< red; i++){
analogWrite(i, red);
}
for(int i = 0; i< red; i++){
analogWrite(i, green);
}

for(int i = 0; i< red; i++){
analogWrite(i, blue);
}
}

After uploaded to board. Windows unplugged PORT COM.

When i plug arduino into USB RBG Led lights, but windows dosn't show arduino, and in arduino ide ports field is empty. I tried to reinstall drivers. This didn't help.

I thnink for loops blocks microcontroller and he is not answering to windows?
I think this for loop is looping over every pin in arduino, making him blocked.
Please help me :(
Is there any option to remove program from arduino? Without using usb?

UPDATE --
I just checked. Every pin is set to HIGHT :( I can light my diode using every pin.....
I think i have to erase this program without using usb, or stop this. How can i do this?

DrAzzy

What kind of Arduino is it?

I would expect that code to do something weird, though - the two arguments to analogWrite should be analogWrite(pin,duty cycle). You're putting all sorts of crazy values in for the pin number, and IIRC putting non-existent pin numbers into the pin manipulation functions may not be "safe".
ATTinyCore for x4/x5/x61/x7/x8/x41/1634/828/x313 megaTinyCore for the megaavr ATtinies - Board Manager:
http://drazzy.com/package_drazzy.com_index.json
ATtiny breakouts, mosfets, awesome prototyping board in my store http://tindie.com/stores/DrAzzy

noindyfikator

#2
Aug 28, 2017, 11:06 pm Last Edit: Aug 28, 2017, 11:13 pm by noindyfikator
It was arduino leonardo.

I just solved problem.
I was fast clicking reset, reset, reset, reset, reset and so on, since "usb loader" or somthing like it ran before my uploaded program, and my computer after ~30 resets of arduino saw board as port, so i was able to upload new program.  

One more time sorry for my ultra bad englisch.

Go Up