How many leds Arduino micro 5V USB ?

Hi everyone !

For a project I put leds just to show that the device is powered. All the leds are connecting with 5V to the GND with a resistor. None are connected to digital pins because they need to bright when the device is powered, so no code is needed.

So my question is, how many leds can I put ? I've seen that is 20mA per digital pin but in my case i don't use that so, what's the max current for 5V pin ? I don't find it in the datasheet. Is it the max current that a USB port can provide ?

Thanks

Most usb connections can provide 500mA. Allow maybe 50mA for the micro itself. So maybe 450mA, but to be safe, 400mA.

The number of leds you can add depends on how much current each led is drawing. That depends on the forward voltage of the led and the value of the series resistor.