This is the same question that I've posted on the Arduino Forums, as there could be someone here who could help me :) I'm using an Arduino Pro Micro 3.3V/8MHz from SparkFun for a project. I've installed the drivers, added support for the board on the IDE and tried uploading a sketch to it - it worked okay. I realize that the bootloader shipped with the board emulates a distinct serial port for uploading, as the normal port is COM5 and the upload port is COM6. Though for this project, code optimization is paramount, so I moved on to the Atmel Studio which I had already used successfully with the UNO. I constructed a simple blinky code for the Micro using the registers and functions:
#define ledpin PC6
#include <avr/io.h>
#include <util/delay.h>
int main(void)
{
DDRC |= (1 << ledpin);
while(1)
{
PORTC |= (1 << ledpin);
_delay_ms(1000);
PORTC &= ~(1 << ledpin);
_delay_ms(1000);
}
}
I can upload it okay through Atmel Studio with the following command in avrdude:
C:\Program Files (x86)\Arduino\hardware/tools/avr/bin/avrdude -C"C:\Program Files (x86)\Arduino\hardware/tools/avr/etc/avrdude.conf" -v -v -patmega32u4 -cavr109 -P\\.\COM6 -b57600 -D -Uflash:w:"$(ProjectDir)Debug\$(ItemFileName).hex":i
To be able to do this, I have to press the reset button twice in less than 750 ms, as the hookup guide sugests (https://learn.sparkfun.com/tutorials/pro-micro--fio-v3-hookup-guide/troubleshooting-and-faq#ts-reset).
The code works, but now I notice that the normal serial port (COM5) never comes back. What could be the cause? I can still upload new code to the Micro, so the bootloader should be okay right?
Thanks for the help in advance :)