AudioDriverKit

RSS for tag

Develop drivers for audio devices using AudioDriverKit.

AudioDriverKit Documentation

Posts under AudioDriverKit tag

10 Posts
Sort by:
Post not yet marked as solved
0 Replies
105 Views
Dear Sirs, when writing an AudioServerPlugin I can use the hosts WriteToStorage/CopyFromStorage functions to save and restore custom properties on restarting the machine. Are there corresponding functions for an audio driver based on AudioDriverKit? What would be the recommended way to save and restore properties so that they are available again after a reboot in an audio driver based on AudioDriverKit? Thanks and best regards, Johannes
Posted Last updated
.
Post not yet marked as solved
1 Replies
215 Views
Dear Sirs, I've written an audio driver based on AudioDriverKit. In my audio callback function I'm receiving calls with io operation IOUserAudioIOOperationWriteEnd and IOUserAudioIOOperationBeginRead as expected which means I see IOUserAudioIOOperationWriteEnd operations during a playback in an application like VLC or the browser and I see IOUserAudioIOOperationBeginRead when recording in Audacity etc.. But when I open the SystemSettings and goto Sound and I select my driver as input I also see calls with IOUserAudioIOOperationWriteEnd which seem to be the just read input data. I can also watch this when starting up Teams. I think the purpose is to add the (mic) input also to the output so you have the chance to listen to yourself. Nevertheless I'd like to fully avoid this but I don't see a way to distinguish between the playback audio data and the input audio data inside this callback. How could I do this? Or even better is there a switch which would completely switch off these callbacks which forward the input to the output? Thanks and best regards, Johannes
Posted Last updated
.
Post not yet marked as solved
0 Replies
105 Views
Hi, I have an idea for an audio application. It does make use of HRTFs in a different way. So I would like to get the HRTF that was made for the user and use it in the application. Is that possible?
Posted
by simmania.
Last updated
.
Post not yet marked as solved
2 Replies
434 Views
Dear Sirs, I've written a Swift App, a C++ application and a Driver Extension using DriverKit and AudioDriverKit. As it works on my development machine now I'd like to give it to some other users and so I'm trying to make a Release Build. I've created a Signing Certificate for "Apple Distribution" which I can use for my Swift App and the C++ application which also both use "com.apple.developer.driverkit.userclient-access". I've been given this entitlement and the "Distribution Support" is for "Development, Ad hoc, App Store, Developer ID". For my Driver Extension I'm using the entitlements "com.apple.developer.driverkit" and "com.apple.developer.driverkit.family.audio" which I've also been given and which show the identical "Distribution Support". But when I try to use my Signing Certificate XCode refuses to use the provisioning profile for the Dext and says "Xcode 14 and later requires a DriverKit development profile enabled for iOS and macOS. Visit the developer website to create or download a DriverKit profile." On the other hand I have to use the same Signing Certificate for my Swift App that embeds the Dext and the Dext itself. How can I create a Signing Certificate for Release mode that works for both, the Swift App and the Dext? Thanks and best regards, Johannes
Posted Last updated
.
Post not yet marked as solved
5 Replies
484 Views
Dear Sirs, I'd like to add an icon to my audio driver based on AudioDriverKit. This icon should show up left of my audio device in the audio devices dialog. For an Audio Server Plugin I managed to do this using the property kAudioDevicePropertyIcon and CFBundleCopyResourceURL(...) but how would you do this with AudioDriverKit? Should I use IOUserAudioCustomProperty or IOUserAudioControl and how would I refer to the Bundle? Is there an example available somewhere? Thanks and best regards, Johannes
Posted Last updated
.
Post not yet marked as solved
3 Replies
659 Views
Dear Sirs, I’d like to write a virtual audio driver that also exchanges data with a application and thus probably also offers a driver extension using IOUserClient. My first implementation was based on the sample https://developer.apple.com/documentation/audiodriverkit/creating_an_audio_device_driver and everything works fine and as expected on my development machine and I can install/uninstall the dext from within my application. But I had to learn that I will not be given the required entitlement com.apple.developer.driverkit.family.audio as AudioDriverKit seems to be not intended to be used for virtual drivers. So I found out that this sample should be used as starting point for virtual audio drivers: https://developer.apple.com/documentation/coreaudio/creating_an_audio_server_driver_plug-in. But this sample does not include a dext offering the IOUserClient interface which I think I need. The next sample I found was https://developer.apple.com/documentation/coreaudio/building_an_audio_server_plug-in_and_driver_extension . This doesn’t use AudioDriverKit and it includes IOUserClient so it seems to be a good start. Nevertheless it also requires some entitlements which are com.apple.developer.driverkit and com.apple.developer.driverkit.transport.usb. The client also probably needs the entitlement com.apple.developer.driverkit.userclient-access. Would I be given these entitlements for a pure virtual audio driver and why would I need com.apple.developer.driverkit.transport.usb? And is there a chance that AudioDriverKit will also be opened for virtual drivers as it seems to be a much more modern approach and doesn’t require a reboot for installing? Thanks and best regards, Johannes
Posted Last updated
.
Post not yet marked as solved
1 Replies
606 Views
Hello, I am trying to run a sample project from Apple's Developer Documentation that creates and interfaces with a DriverKit Dext. The project can be found here: Creating an Audio Device Driver. I have followed all the steps in the README.md file: downloading the code, enabling automatic signing, building the app, moving it to the Applications folder, and launching it. I then open the app, press "Install Dext", enable it through System Preferences, and receive the message "SoundboardDriver has been activated and is ready to use." However, the audio device does not appear in the MIDI app, there is no mention of it in the IORegistry, and I get the message “Driver extension is not running” when I try to press "Open User Client". Is there another step I need to follow to get the app running? Perhaps it's an entitlement issue? I don't see any error/fault message in the console app relating to the app or driver. I am running MacOS 13.4.1 (22F82) and Xcode 14.3.1 (14E300c). I have tried with and without SIP enabled, but the issue persists. Any help or guidance would be greatly appreciated. Best, Henry
Posted Last updated
.
Post not yet marked as solved
2 Replies
908 Views
Hello, I'm trying to test the example code for the AudioDriverKit and the "Open User Client" button returns a kIOReturnNotPermitted error. Using the standard entitlements that come with the example and I'm signing to run locally. SIP is disabled and I'm using systemextensionsctl developer on When the "Open User Client" button is pressed, I see the following calls into the dext: SimpleAudioDriverUserClient::init SimpleAudioDriverUserClient::Start SimpleAudioDriverUserClient::Stop SimpleAudioDriverUserClient::free None return any errors. Seems like this is a permission issue, but since this is just the straight example code, it seems like it should work out-of-the-box. Any clues as to why this is failing? Thank you!
Posted
by PCBuff.
Last updated
.
Post not yet marked as solved
7 Replies
1.2k Views
Hi, I'm a little newbie on MacOS but did audio development for many years on other systems. Now I started some development on MacOS and tried to get this SimpleAudioDriver sample running. Compilation works fine and when I try to install the dext I'm prompted for my credentials. Afterwards "systemextensionsctl list" shows the dext as enabled and active but the SimpleAudio device is not shown in the "Audio MIDI Setup" and the SimpleAudioDriverApp says the extension is not running. I already tried various things from "csrutil disable" to "systemextensionsctl developer on" to "sudo nvram boot-args=-arm64e_preview_abi" My console log shows error entries like this: Error occurred while handling request "DextLaunch(arguments: Optional(["Check In Token": 18447, "Driver Extension Server Tag": 4294973749, "CFBundleIdentifier": de.bebetterorganized.dev.SimpleAudio.Driver, "DriverKit Reslide Shared Cache": 0, "Driver Extension Server Name": de.bebetterorganized.dev.SimpleAudio.Driver, "kOSBundleDextUniqueIdentifier": <3eb592b5 11e19191 027e272f 7fc6f5cc f24eaa62 367de83c 2fc697b5 4db10ed7>]))": Error Domain=NSPOSIXErrorDomain Code=8 "Exec format error" Now I'm not sure whether my extension is not loaded at all or whether it's just not detected as audio device and not connectable for any reason. I'm trying all these things on a MacBook Air with Apple M2 CPU, MacOS 13.2.1 and XCode Version 14.2 (14C18), MacOS Any hint would be appreciated, thanks a lot, Johannes
Posted Last updated
.
Post not yet marked as solved
0 Replies
537 Views
Hello, I have been creating an audio recording app that records audio in the background. For example, you are just starting to pull over in your car, or are walking down an alley, you hit "record" and the app will record in the background, allowing you to use your phone otherwise like normal while you are going through the tense time. I have noticed that, on any audio recording app, once you start recording audio, all audible notification tones get muted. I have narrowed the issue down to the IOS audio driver. That said, is there a way to request a revision to this audio driver issue, in the next IOS update? Thanks!
Posted Last updated
.