Add run and stop to event loop