<commit_before>//
//  main.swift
//  AudioKit
//
//  Created by <NAME> and <NAME> on 12/22/14.
//  Copyright (c) 2014 <NAME>. All rights reserved.
//

import Foundation

class Instrument : AKInstrument {

    override init() {
        super.init()

        let frequencyShifter = AKLowFrequencyOscillator()
        frequencyShifter.type = AKLowFrequencyOscillatorType.BipolarSquare
        frequencyShifter.amplitude = 100.ak;
        frequencyShifter.frequency = 0.25.ak
        connect(frequencyShifter)

        let operation = AKPortamento(input: frequencyShifter)
        connect(operation)

        let sine = AKOscillator()
        sine.frequency  = operation.plus(880.ak)
        connect(sine)

        connect(AKAudioOutput(audioSource:sine))
    }
}



let instrument = Instrument()
AKOrchestra.addInstrument(instrument)

AKOrchestra.testForDuration(10)

instrument.play()
<commit_msg>Updated AKPortamento test to add logging<commit_after>//
//  main.swift
//  AudioKit
//
//  Created by <NAME> and <NAME> on 12/22/14.
//  Copyright (c) 2014 <NAME>. All rights reserved.
//

import Foundation

let testDuration: Float = 10.0

class Instrument : AKInstrument {

    override init() {
        super.init()

        let frequencyShifter = AKLowFrequencyOscillator()
        frequencyShifter.type = AKLowFrequencyOscillatorType.BipolarSquare
        frequencyShifter.amplitude = 100.ak;
        frequencyShifter.frequency = 0.25.ak
        connect(frequencyShifter)

        let portamento = AKPortamento(input: frequencyShifter)
        connect(portamento)

        let sine = AKOscillator()
        sine.frequency  = portamento.plus(880.ak)
        connect(sine)
        
        enableParameterLog(
            "Frequency = ",
            parameter: sine.frequency,
            frequency:0.1
        )
        
        connect(AKAudioOutput(audioSource:sine))
    }
}



let instrument = Instrument()
AKOrchestra.addInstrument(instrument)

AKOrchestra.testForDuration(testDuration)

instrument.play()

{'fraction_non_alphanumeric': 0.09751243781094528, 'fraction_numerical': 0.022388059701492536, 'mean_word_length': 2.683150183150183, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7047273', 'n_tokens_mistral': 676, 'n_tokens_neox': 586, 'n_words': 120}