what are these pin spots for?

looking at my Mega2560 and the Uno, and I was wondering, what are these for?


ICSP for the ATmega8u2 used for USB-to-Serial conversion.

I'm not talking about the ICSP header, I'm talking about the 4 spots right next to the ICSP header.

also this is the R3 which uses a 16U2 instead of the 8U2.

The schematic shows them as connected to PORTB Bits 4-7. Not much on those pins except PCINT4-7

what are those two things?

[sorry, my experience comes from an electronics learning lab from radio shack, I'm better with programming and even that I have little experience, my Mega2560 (R3) is my pride and joy past analog and very basic digital electronics]

EDIT: scratch that, just looked up the datasheet for the 16u2 and it appears that PCINT4-7 are mostly just interrupts.

Well I'm guessing they were just intended as GPIO. I had a thought a while ago that you could reprogram the usb to serial chip to tell the arduino (by writing a pin high/low) when there's a usb connection -- that would be impossible without extra pins broken out.

People had used the FTDI chip (the previous USB->serial converter) in "bit bang" mode to program the bootloader into the main CPU. In theory, having these pins broken out to pads would allow something like that with the new chip as well.