Whenever we're dealing with more than a few miliamps we need to consider power dissipation. And for the LED Driver for the RGB Tumbler project I'm using three 50 mA LEDs connected to a SOIC-16 LED driver. That's at least 150 mA through a fairly small IC so let's look at the numbers.
The problem is always the temperature at the "junction" inside the IC. If this is too high, the IC will stop working. If it is much too high it will melt, burn or explode. And in most cases that is less than desirable.
Most datasheets list a "maximum junction temperature". For the CAT4109 LED driver, "junction temperature range" is listed as -40 to +150 °C. And it also has a thermal shutdown feature that will cut power if the temperature exceeds 150 °C (so it will just stop working and not explode).
An important factor is "thermal resistance" (written as the Greek letter theta, θ, and specified in °C/W). If you have read this article about choosing a MOSFET you'll know about thermal resistance and a couple of calculations. If you haven't read it, it will suffice to know that thermal resistance is a measure of how much the temperature will rise per Watt that is pulled through the device. Lower thermal resistance is better (since the device won't heat up so much).
Also, we need to be aware of the "ambient temperature" – which is how hot it is where the IC operates (if we're in Sibiria in the middle of the winter the temperature needs to rise a lot before reaching 150 °C).
Thermal resistance is often split into θJC which means thermal resistance from junction to casing and θCA which is thermal resistance from casing to ambient.
Junction-to-casing depends on the package of the IC (DIP, TQFP, SOIC, ...) and casing-to-ambient depends on the PCB layout (large copper areas will help dissipate heat and thus give a lower thermal resistance) and possible use of heatsinks. We are interested in the overall thermal resistance – θJA or thermal resistance from junction to ambient which equals θJC + θCA.
A typical value for θJA for a SOIC-16 package is 115 °C/W. (Refer to this table for typical values.)
The basic equation is this:
TJ = Tamb + Pd * θJA
Or in words: "the junction temperature is the ambient temperature plus power (in Watts) times thermal resistance from junction to ambient (in °C/W)".
And what is Pd? As usual P = V * I. And we need to consider both the power the IC is using and the power that is dissipated from the LED currents. So we get:
Pd = (Vdd * Idd) + Ʃ( VLEDn * ILEDn)
The first part is IC supply voltage times IC current. Which in our case is 3 V and 10 mA (according to the datasheet).
The last part means "the sum of V * I for the individual LED pins". And this differs from pin to pin since the forward voltage for the R, G and B LEDs are different. The voltage at the LED pins is the LED supply voltage (5V) minus the forward voltage of the LEDs (2 V for the red LED and 3.2 V for the green and blue LEDs). And the LED current is 50 mA.
So we get (I've omitted the units, but it all matches):
Pd = (3 * 0.01) + ((5-2) * 0.05 + (5-3.2) * 0.05 + (5-3.2) * 0.05) = 0.36 W
And what kind of temperature will that give us (let's assume an ambient temperature of 35 °C – which is hotter than it ever gets in Denmark):
TJ = 35 + 0.36*115 = 76.4 °C
Which is far enough below the 150 °C limit so everything is good.
The CAT4109 datasheet has a nice explanation of all this as well. In their example calculation they use an ambient temperature of 60 °C and a thermal resistance of 74 °C/W which is quite a bit lower than our 115 °C/W but they assume a PCB layout with "double−sided printed circuit board with two square inches of copper allocated for heat spreading". Which explains the lower thermal resistance.