     
     @IBOutlet var statusLabel: NSTextField!
     
-    let instrument = AKInstrument()
-    let oscillator = AKFMOscillator()
+    let instrument = AKFMOscillatorInstrument()
+    let note = AKFMOscillatorNote()
+
 
     override func viewDidLoad() {
         super.viewDidLoad()

        println(serialCommunicator.switchState)
        
        if serialCommunicator.switchState == true {
            instrument.play()
            self.statusLabel.stringValue = "Stop"
        } else {
            instrument.stop()

    
    func potOneValueChanged(notification: NSNotification){
        println(serialCommunicator.potentiometerOneValue)
        note.frequency.setValue(Float(serialCommunicator.potentiometerOneValue * 4), afterDelay: Float(0))
    }
    
    func potTwoValueChanged(notification: NSNotification){
        note.modulationIndex.setValue(Float(serialCommunicator.potentiometerTwoValue / 4), afterDelay: Float(0))
        println(serialCommunicator.potentiometerTwoValue)
    }
    
