Added pause/resume/stop functionality