The lite version is free, but I think it only allows you to set up a single rule.

Tasker looks like the way to go if you're willing to pay for an app tho - I'll be giving it a go in the near future, especially as Setting Profiles seems to have been encountering a few issues for me lately, such as not automatically changing the rules (Desire running 2.1).