your line length is too long for the serving pressure that you require (irrespective to temperatre, and therefore disregarding the required carbonation level. Although, both these bits of info would be useful). 5mm ID line, at 3m in length, would require aprox 110kPa for a balanced pour at this length, assuming your tap height is level with the top of the keg rubber. (which is common. Or an even higher pressure, if the tap is higher.) So serving at a lower pressure than that required by the line length will cause the beer to degas in the liine itself, forming bubbles behind the tap, which in turn causes frothing. The beer is therefore undercarbonated relative to the length of the line.
Note that I am not sugesting that the beer itself is undercarbonate, or that the serving pressure is incorrect: the pressure is relative to the temperature of the beer and the desired carbonation level. Rather, I am saying that your line is too long.
You have the following choices:
What temperature you want, and
what carbonation level you want.
Based on these choices, you are then presented with a set pressure to achieve this.
Based on this set pressure, you are then presented with a set line length to balance the system, based on tap height and line resistance.
search for, and download, crozdogs carbonation chart (I believe v1.2 may be the latest. Pls correct me if I'm wrong), and enter your specific data.
What you will find is that (assuming tap height of 60cm above centre of keg), you will need ~1.7m of 5mm Line for a balanced pour. (which would give you aprox 2.4 volumes of CO2 at 4C; lower at higher temps, higher at lower temps).
and who said I couldn't be f&^$ing serious??