There is no way to specify rules for different subdomains within a single robots.txt file. A given robots.txt file will only control crawling of the subdomain it was requested from. If you want to block some subdomains and allow others, then you need to serve different robots.txt files from the different subdomains.
For example, if you want to allow crawling of http://crawlme.example.com/, but you want to block crawling of http://nocrawl.example.com/ then:
http://crawlme.example.com/robots.txt should contain:
# Allow everything:
User-agent: *
Disallow:
and http://nocrawl.example.com/robots.txt should contain:
# Block everything:
User-agent: *
Disallow: /