4

I'm currently trying to switch my app to AudioKit. As I understand AudioKit, changing the output device during playback from headphone to build-in speaker by pulling the plug should work like a charm.

Here is a little test routine I wrote in a cocoa app:

let player = AKPlayer(url: URL(fileURLWithPath: "Some existing music file"))

func applicationDidFinishLaunching(_ aNotification: Notification) {
    do {
        AudioKit.output = player
        try AudioKit.start()
        player?.play()
    } catch {

    }
}

I'm getting the following error messages:

2018-12-14 10:16:23.947675+0100 TestAudioKit[2829:171503] [AudioHAL_Client] HALC_ShellPlugIn.cpp:1118:HAL_HardwarePlugIn_DeviceStop: HAL_HardwarePlugIn_DeviceStart: no device 2018-12-14 10:16:23.947740+0100 TestAudioKit[2829:171503] [AudioHAL_Client] HALPlugIn.cpp:536:DeviceStopIOProc: HALPlugIn::StopIOProc: got an error from the plug-in routine, Error: 560947818 (!obj) 2018-12-14 10:16:23.977030+0100 TestAudioKit[2829:171503] [AudioHAL_Client] HALC_ShellPlugIn.cpp:996:HAL_HardwarePlugIn_DeviceDestroyIOProcID: HAL_HardwarePlugIn_DeviceDestroyIOProcID: no device 2018-12-14 10:16:23.977091+0100 TestAudioKit[2829:171503] [AudioHAL_Client] HALPlugIn.cpp:454:DeviceDestroyIOProcID: HALPlugIn::DeviceCreateIOProcID: got an error from the plug-in routine, Error: 560947818 (!obj) 2018-12-14 10:16:24.595967+0100 TestAudioKit[2829:171503] [AudioHAL_Client] HALB_IOThread.cpp:251:_Start: HALB_IOThread::_Start: there already is a thread 2018-12-14 10:16:24.596085+0100 TestAudioKit[2829:171503] [AudioHAL_Client] HALC_ShellPlugIn.cpp:817:HAL_HardwarePlugIn_ObjectHasProperty: HAL_HardwarePlugIn_ObjectHasProperty: no object 2018-12-14 10:16:24.596203+0100 TestAudioKit[2829:171503] [AudioHAL_Client] HALC_ShellPlugIn.cpp:817:HAL_HardwarePlugIn_ObjectHasProperty: HAL_HardwarePlugIn_ObjectHasProperty: no object 2018-12-14 10:16:24.596228+0100 TestAudioKit[2829:171503] [AudioHAL_Client] HALC_ShellPlugIn.cpp:817:HAL_HardwarePlugIn_ObjectHasProperty: HAL_HardwarePlugIn_ObjectHasProperty: no object 2018-12-14 10:16:24.596285+0100 TestAudioKit[2829:171503] [AudioHAL_Client] HALC_ShellPlugIn.cpp:817:HAL_HardwarePlugIn_ObjectHasProperty: HAL_HardwarePlugIn_ObjectHasProperty: no object 2018-12-14 10:16:24.596327+0100 TestAudioKit[2829:171503] [AudioHAL_Client] HALC_ShellPlugIn.cpp:817:HAL_HardwarePlugIn_ObjectHasProperty: HAL_HardwarePlugIn_ObjectHasProperty: no object 2018-12-14 10:16:24.596366+0100 TestAudioKit[2829:171503] [AudioHAL_Client] HALC_ShellPlugIn.cpp:817:HAL_HardwarePlugIn_ObjectHasProperty: HAL_HardwarePlugIn_ObjectHasProperty: no object 2018-12-14 10:16:24.596380+0100 TestAudioKit[2829:171503] [AudioHAL_Client] HALC_ShellPlugIn.cpp:817:HAL_HardwarePlugIn_ObjectHasProperty: HAL_HardwarePlugIn_ObjectHasProperty: no object 2018-12-14 10:16:24.615329+0100 TestAudioKit[2829:171503] [AudioHAL_Client] HALC_ShellPlugIn.cpp:817:HAL_HardwarePlugIn_ObjectHasProperty: HAL_HardwarePlugIn_ObjectHasProperty: no object 2018-12-14 10:16:24.615374+0100 TestAudioKit[2829:171503] [AudioHAL_Client] HALC_ShellPlugIn.cpp:817:HAL_HardwarePlugIn_ObjectHasProperty: HAL_HardwarePlugIn_ObjectHasProperty: no object 2018-12-14 10:16:24.622916+0100 TestAudioKit[2829:171790] [AudioHAL_Client] HALSystem.cpp:1688:AudioObjectPropertiesChanged: AudioObjectPropertiesChanged: no such object 2018-12-14 10:16:24.622962+0100 TestAudioKit[2829:171504] [DDAgg] DefaultDeviceAggregate.cpp:58:GetPreferredStereoChannels: Error getting preferred stereo channels from device 70: 'who?' 2018-12-14 10:16:24.623648+0100 TestAudioKit[2829:171504] [DDAgg] DefaultDeviceAggregate.cpp:108:GetPreferredChannelLayout: Error getting preferred channel layout from device 70: 'who?'

Any suggestions?

MacOS 10.14.2

Thanks Chris

Chris
  • 41
  • 4

0 Answers0