find the on/off times in a light curve