Need help with loop time/interrupt programming