title: How to create a background threaded on interval function call in python?
body: <p>I am trying to implement a heartbeat call that works in the background. How do I create a threaded on interval call of say every 30 seconds, which calls the following function:</p>
  
  <pre><code>self.mqConn.heartbeat_tick()
  </code></pre>
  
  <p>Also how would I stop this thread?</p>
  
  <p>Many thanks.</p>