             self.mix = mix
 
             internalEffect = AVAudioUnitEffect(audioComponentDescription: _Self.ComponentDescription)
+            au = AUWrapper(au: internalEffect.audioUnit)
+
             super.init()
 
             avAudioNode = internalEffect
             AudioKit.engine.attach(self.avAudioNode)
             input.addConnectionPoint(self)
-            internalAU = internalEffect.audioUnit
 
             // Since this is the Decimator, mix it to 100% and use the final mix as the mix parameter
-            AudioUnitSetParameter(internalAU!, kDistortionParam_DecimationMix, kAudioUnitScope_Global, 0, 100, 0)
 
-            AudioUnitSetParameter(internalAU!, kDistortionParam_Decimation, kAudioUnitScope_Global, 0, Float(decimation) * 100.0, 0)
-            AudioUnitSetParameter(internalAU!, kDistortionParam_Rounding, kAudioUnitScope_Global, 0, Float(rounding) * 100.0, 0)
-            AudioUnitSetParameter(internalAU!, kDistortionParam_FinalMix, kAudioUnitScope_Global, 0, Float(mix) * 100.0, 0)
-            //turn off the other distortion effects
-            AudioUnitSetParameter(internalAU!, kDistortionParam_PolynomialMix, kAudioUnitScope_Global, 0, 0, 0)
-            AudioUnitSetParameter(internalAU!, kDistortionParam_RingModMix, kAudioUnitScope_Global, 0, 0, 0)
-            AudioUnitSetParameter(internalAU!, kDistortionParam_DelayMix, kAudioUnitScope_Global, 0, 0, 0)
+            au[kDistortionParam_Decimation] = decimation * 100
+            au[kDistortionParam_Rounding] = rounding * 100
+            au[kDistortionParam_FinalMix] = mix * 100
+
+            au[kDistortionParam_PolynomialMix] = 0
+            au[kDistortionParam_DelayMix] = 0
+            au[kDistortionParam_DelayMix] = 0
     }
 
     // MARK: - Control


    public static let ComponentDescription = AudioComponentDescription(appleEffect: kAudioUnitSubType_Distortion)

    internal var internalEffect = AVAudioUnitEffect()
    internal var internalAU: AudioUnit? = nil

    fileprivate var lastKnownMix: Double = 1


    open var rounding: Double = 0 {
        didSet {
            rounding = (0...1).clamp(rounding)
            au[kDistortionParam_Rounding] = rounding * 100
        }
    }

