added monitoring program
added variable delay to monitoring program