Helmet law in Spain? I was told that there is a fine of €300 for cycling on a "carretera" in Spain without a helmet.  But it's possible the guy just wanted to sell me a helmet.  I'm not completely sure what exactly distinguishes a carretera from any other road, but on this trip, I don't have that helmet with me and several police have seen me riding.

A web search gets more advertisements than information.  Anyone know what the law is there?  Extra credit if you have a link to the official text.  (I can read Spanish.)
http://www.bikeramble.com/do-you-need-a-helmet-spain/  says 

Well, the short answer is: it depends.

There is a mandatory helmet law for cyclists in Spain, but it is seldom enforced. 

Are you required by law to wear a helmet in Spain?  Yes. But there are four notable exceptions:


You don’t need to wear a helmet in Spain if you are in an urban area.
Since 2004, it has been mandatory to wear a helmet for all cyclists outside urban areas. It is not required in urban areas. In 2013, it was made mandatory for all cyclists, everywhere, to wear a helmet, even in urban areas. This was met by opposition from council bodies and the new law was quickly overturned. However, it is still necessary for under 16’s to wear a helmet at all times. The definition of “urban area” is quite loose and everything bigger than a couple of houses should qualify.
UPDATE - This exemption was deleted in 2015 and NO LONGER APPLIES. You didn’t need to wear a helmet in Spain if it was too hot.
What classifies as too hot? Probably anywhere in the south of Spain from May-September, or all of Spain from June-August. The exception applies because wearing a helmet in extreme heat is pretty uncomfortable, and would completely deter some from cycling at all.
You don’t need to wear a helmet in Spain if you are going up a hill.
Convenient as I usually find that if I’m not in an urban area, and it’s not that hot, I’m going up a hill.
You don’t need to wear a helmet in Spain if you are a professional.
Get paid for cycling a bicycle? Great, then you are probably already subject to hundreds of rules, one of which is that you must wear a helmet at all times!