title: Basics : Sending a signal from an external hardware connected via USB port to android phone to make custom app do stuff
body: <p>I just need some initial directions as I am new when it comes to electronic hardware and android phone/app interaction. I am comfortable in both domains within their boundaries.</p>
  
  <p>I have a black box electronic circuit. To simplify things lets assume all it does is, send binary 1 or 0 i.e. electric On or Off pulse. I need to connect this circuit to the android phone via USB(either Host/accessory mode) and want my android app to react to this pulse.</p>
  
  <p>If possible - start the app when the phone receives 1/ON signal 
                OR display an "Switched ON" dialog message while the app is running in background as a service</p>
  
  <p>Please dont worry too much about the electronics part. I'm aware that this is a software/programming forum.</p>
  
  <p>e.g. black box : a electronic thermometer that sends a pulse/1/On signal if the temperature goes to 100 degrees Centigrade OR anything similar that's on a simple circuit board(no processor or programming language/architecture dependent) and could trigger a signal that could be sent to the android phone to inform my app that the event occurred.</p>
  
  <p>another even simpler example, an earphone that has a connect/disconnect call button connected to audio jack of the android phone. i just need to replicate this functionality. instead or ear phone, my electronic BB and instead of phone call program, a custom android app.</p>
  
  <p>Links, DIY projects, Tuts anything will be really helpful</p>