looks like setInterval() would be a better fit