title: Python time counter
body: <p>I have data coming in from an outside source (serial port in this case) roughly every 2.5 seconds.<br>
  I want to store ( in mysql) a sample of this data every 5 minutes, not every 2.5 seconds.<br>
  How would i implement this in python?<br>
  One can probably not use a sleep function since this will stop the rest of the script.  </p>