"Arduino Micro" + ICSP + Serial Class

Hi there!

I'm using Arduino Micro1, and I've write the sketch below...

void setup() { 
  Serial.begin(9600); 
  while (!Serial); 
}

void loop() { 
  Serial.print("a");
  delay(1000);
}

It works fine when I upload using the button "->" on IDE: "a", "a", "a"... on serial monitor. But it fails when I upload using my programmer (an usbasp2): the sketch is uploaded successfully, but no "a", at all.

I think that is due to the fact that the "Serial" class is implemented "inside" the bootloader3. And when I use the programmer, it's gone, right?

Is there some way to make it works? I need overwrite the bootloader, but I need, as well, serial communication with the computer through the USB connector.

Thanks!

1http://produto.mercadolivre.com.br/MLB-551587630-gravador-avr-usbasp-atmel-cabo-adaptador-arduino-_JM
2http://arduino.cc/en/Main/arduinoBoardMicro
3http://arduino.cc/en/Guide/ArduinoLeonardoMicro?from=Guide.ArduinoLeonardo#toc6

I think that is due to the fact that the "Serial" class is implemented "inside" the bootloader3. And when I use the programmer, it's gone, right?

Is there some way to make it works? I need overwrite the bootloader, but I need, as well, serial communication with the computer through the USB connector.

You could look into incorporating LUFA directly in your code as a library. If you do try this, you may need your own VID/PID pair if this is a commercial effort.

I understand that Dean has some examples in the LUFA downloads. Docs are here:
http://www.fourwalledcubicle.com/files/LUFA/Doc/