title: Keeping an app running in the background
body: <p>I have a mobile application that revolves around a timer that counts down on screen and sends various things such as text messages when the timer reaches a certain time along with changing color, vibrating etc etc. Is there a way to keep the app running in the background constantly so that it is not killed off? I am using a PhoneGap service so PhoneGap plugins are an option. I have tried one plugin called "Background Mode" here is the <a href="https://github.com/katzer/cordova-plugin-background-mode/tree/ac5fef831dbf9e567277dc900389923bd9bc7714" rel="nofollow">link to the documentation</a>. However this doesn't seem to work 100% of the time. </p>
  
  <p>PhoneGap generates a config.xml, where I can change some of the properties/settings of the app. Here are the propeties/preferences (background related ones) I have defined in the config file.</p>
  
  <pre><code>&lt;preference name="exit-on-suspend" value="false" /&gt;
  &lt;preference name="KeepRunning" value="true" /&gt;
  &lt;gap:plugin name="de.appplant.cordova.plugin.background-mode" version="0.5.0" /&gt;
  </code></pre>
  
  <p>Any suggestions would be appreciated. </p>
  
  <p>Thanks.</p>