a number of logic problems, some code ordering changes, a missing global, and a new column in the db for more correct idle tracking...