     open var expansionThreshold: Double = 2 {
         didSet {
             expansionThreshold = (1...50).clamp(expansionThreshold)
-            AudioUnitSetParameter(
-                internalAU!,
-                kDynamicsProcessorParam_ExpansionThreshold,
-                kAudioUnitScope_Global, 0,
-                Float(expansionThreshold), 0)
+            au[kDynamicsProcessorParam_ExpansionThreshold] = expansionThreshold
         }
     }
 


            internalEffect = AVAudioUnitEffect(audioComponentDescription: _Self.ComponentDescription)
            AudioKit.engine.attach(internalEffect)
            internalAU = internalEffect.audioUnit
            AudioKit.engine.connect((effectGain?.avAudioNode)!, to: internalEffect)
            AudioKit.engine.connect(internalEffect, to: mixer.avAudioNode)

            super.init()
            avAudioNode = mixer.avAudioNode

            AudioUnitSetParameter(internalAU!, kDynamicsProcessorParam_ExpansionRatio, kAudioUnitScope_Global, 0, Float(expansionRatio), 0)
            AudioUnitSetParameter(internalAU!, kDynamicsProcessorParam_ExpansionThreshold, kAudioUnitScope_Global, 0, Float(expansionThreshold), 0)
            AudioUnitSetParameter(internalAU!, kDynamicsProcessorParam_AttackTime, kAudioUnitScope_Global, 0, Float(attackTime), 0)
            AudioUnitSetParameter(internalAU!, kDynamicsProcessorParam_ReleaseTime, kAudioUnitScope_Global, 0, Float(releaseTime), 0)
            AudioUnitSetParameter(internalAU!, kDynamicsProcessorParam_MasterGain, kAudioUnitScope_Global, 0, Float(masterGain), 0)
    }

    /// Function to start, play, or activate the node, all do the same thing

    open var releaseTime: Double = 0.05 {
        didSet {
            releaseTime = (0.01...3).clamp(releaseTime)
            au[kDynamicsProcessorParam_ReleaseTime] = releaseTime
        }
    }

