Pro micro not showing up in com port


I flashed a hex file on my Arduino pro micro for a keyboard I was making. The keyboard was not working properly so I wanted to try to write some code on the Arduino IDE first. When I go to the IDE my board does not show up as a com port. Can someone tell me what I can do to fix this issue?

Did you use an ISP programmer to flash the hex file, or did you just have the Pro Micro connected to your computer via the USB cable like usual?

I had the Arduino connected through a usb cable

Due to the USB stack running on the same ATmega32U4 microcontroller as your program on the Pro Micro, it is possible for code in your program to break the USB functionality, which can lead to the port no longer appearing.

Fortunately, the upload code (bootloader) is stored in a separate section of memory and can not be broken by the program code.

The only tricky thing is that the bootloader has to be activated at just the right time during the upload. Normally this is done by some special code that runs in the background of your sketch code recognizing a 1200 baud connection as the signal to reset the microcontroller and start the bootloader. However, in your current situation, that system won't work so you'll need to manually reset the board to activate the bootloader.

You need to get the timing right. If you do the reset too early, the bootloader will have already timed out by the time the upload starts. The tricky thing is that when you press the "Upload" button in the Arduino IDE, it first compiles your sketch before starting the actual upload. So you need to wait until after the compilation finishes before resetting the board.

Try this:

  1. Prepare some way to reset your Pro Micro by momentarily connecting the RST pin to the GND pin. This could be done with a wire or even some metal tweezers.
  2. Select Sketch > Upload from the Arduino IDE's menus.
  3. Watch the black console window at the bottom of the Arduino IDE window until you see something like this:
    Sketch uses 444 bytes (1%) of program storage space. Maximum is 30720 bytes.
    Global variables use 9 bytes (0%) of dynamic memory, leaving 2039 bytes for local variables. 
    Maximum is 2048 bytes.
  4. Immediately reset the Arduino board.

After that, the sketch should upload successfully and you should then see a port for your board and be able to resume normal uploads.

it says error compiling for board.

I also think the Arduino is not recognized in any com port.

Screenshots of errors are most of the time useles; use the copy error messages in the orange bar to copy errors to the clipboard and next paste them here in a reply using code tags.

Your sketch is missing both the setup() function and the loop() function. Below the minimum sketch

void setup()
  // put your setup code here, to run once:


void loop()
  // put your main code here, to run repeatedly:


Just realized that I have added a simple blink program. though when I try to upload the code an error message pops up. I can not copy the message because when it comes the IDE is still stuck on uploading.

Do this:

  1. Click on the black console pane at the bottom of the Arduino IDE window.
  2. Press Ctrl+A to select all the text.
  3. Press Ctrl+C to copy the selected text to the clipboard.
  4. Open a forum reply here by clicking the Reply button.
  5. Click the </> icon on the post composer toolbar. This will add the forum's code block markup (```) to your reply to make sure the output is correctly formatted.
    Code block
  6. Press Ctrl+V. This will paste the copied output into the code block.
  7. Move the cursor outside of the code tags before you add any additional text to your reply.
  8. Click the Reply button to post the output.

Thanks for the help ,the problem is resolved. I closed all other apps which removed the error message and then I was able to reset my Arduino as you previously instructed and it uploads all the programs fine now.

You're welcome. I'm glad to hear it's working now. Enjoy!

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.