top-level function for nonstop schedule