Step reset, don't reset on ii=waveNum, nicer output