added sleep statements to encodertest