Lights to indicate the outside temperature- recreate from Webcore

I had a Piston in Webcore that I want to recreate in Rule, but I can't see how I can do it. Any clues anybody?

Basically it checks the temperature and if it's above a certain value sets a light one colour, if it's in a certain range then another colour, and below a certain range flash a colour for a couple of minutes.

Regardless, after 5 minutes reset the light to the value it had before the rule ran.

I have a rule that changes a fan based on range. If your question hasn't been answered later, I'll post my rule when I get home to get you started. There are always several different ways to get the same result.

trigger: temperature changed

actions:
capture light status
if temp > 80
color = red
else if temp> 70
color = yellow
else if temp > 60
color = orange
else
color = blue
end if
delay 5 min
restore light

I'll give that a try - I like the simple logic that does away with the need for <> and <= etc. I also need to check out the Capture and Restore functions. I hadn't spotted those.