Added wait for flow sensor