title: Programmatically detect if app is being run on device or simulator
body: <p>I'd like to know whether my app is being run on device or simulator at run time.  Is there a way to detect this?</p>
  
  <p>Reason being to test bluetooth api with simulator:
  <a href="http://volcore.limbicsoft.com/2009/09/iphone-os-31-gamekit-pt-1-woooohooo.html" rel="noreferrer">http://volcore.limbicsoft.com/2009/09/iphone-os-31-gamekit-pt-1-woooohooo.html</a></p>