21za2323rzcvzxcv:
- Do a loopback test, even though the USB is integrated on the SAMD chip?
As you guessed, the loopback test is not relevant for the boards with native USB capability like your MKR1000. The sole purpose of the loopback test is to check the functioning of the external USB chip you find on the boards like Uno, Mega, and Nano.
21za2323rzcvzxcv:
2) Follow hiduino advice and press reset button, just before uploading starts in order to override core USB sketch?
That's close, but it's actually far more convenient with the MKR1000.
The tricky thing about the boards with native USB functionality like your board is that the USB code that creates the CDC serial port is running on the same microcontroller as your sketch. This means your sketch code can break the USB code, or stop it from running.
Fortunately, there is an easy way to recover from this situation:
- Press and release the reset button on your board quickly twice. You should now see the LED on the board pulsing, which means the bootloader is running. The double press causes the bootloader to run indefinitely (until the board is reset, powered off, or an upload is done), which means you don't need to get the timing of the reset just right.
- Select the port of your board from the Tools > Port menu. The port number may be different when the bootloader is running so don't assume you already have the correct port selected.
- Start an upload in the Arduino IDE.
The upload should now finish successfully. After this, you should be able to go back to doing normal uploads without needing to press the reset button. If you still need to do the reset trick to do uploads after this, the problem may be caused by your code. You can verify this by uploading a simple sketch like File > Examples > 01.Basics > BareMinimum.
21za2323rzcvzxcv:
3) Buy an expensive Atmel-ICE programmer?
If you don't get a pulsing LED after doing a double reset, this does indicate that the bootloader is not running. The most common cause I have observed (and experienced
) of that is uploading to a SAMD board like the MKR1000 when you have the Nano 33 BLE selected from the Arduino IDE's Boards menu.
This can be fixed by flashing the bootloader to the board (AKA "burn bootloader"), and the Atmel ICE is a nice tool for doing this. But there are other cheaper options I can recommend, which even include just using a spare Arduino board! I will wait until we determine whether that is necessary before boring you with all the details, but anyone interested in the subject can see instructions here:
21za2323rzcvzxcv:
4) Has the Windows port getting recognized anything to do with the bootloader at all?
Only while the bootloader is running. Normally, the bootloader only runs during the uploads. However, with the double reset trick I shared above, you cause the bootloader to run constantly. This means that, even when the sketch code is completely broken, the relatively inviolate bootloader code acts as a fallback.