- Nov 6, 2016
Dumb question, is it worth our time to file a radar (bug) report to Apple regarding this issue?I have been trying to narrow down the possible place for error(s) in pushing audio out over my RX 460 card. So, of course I wrote another script to allow me to test various options. I am putting this script up here for those that want to try it to see if they have similar results. My conclusion is that for my situation, I do think (as others have reported) the Apple-AMD 9510 controller and 4100 kext are the problem in that "they" are sending a malformed header to the receiving equipment whether that equipment is a tv, monitor or a/v receiver. So here is the script. It plays one song through whatever audio out device you already have [this does not add new devices — if you want to use hdmi / dp audio outputs, you will probably have to use one of the SSDT.aml files available to gain that capability before this script will be able to send audio output to those devices.]
This script uses part of the built in CoreAudio toolbox that Apple includes in macOS. Most scripts however, cannot call those tools directly. So first you will have to install a wrapper library that allows the script to work with the CoreAudio tools.
This is very easy to do. Open the Terminal app (you knew that was coming right ). Then type in the command:
sudo gem install coreaudio
followed by pressing the return key. You will have to enter your password (also followed by the return key.)
macOS will go download the necessary wrapper library and install it for you. No fuss, no muss. If you are (as very well you might be) curious about the library, the source code is found here:
location of the source code: https://github.com/nagachika/ruby-coreaudio
location of the installer: https://rubygems.org/gems/coreaudio/versions/0.0.12
These type of files get installed in one of three places, in this case, it should be the first location:
location of the installed gem file
Once the installation is finished, drag the script I included to your desktop and remove the .zip extension. The file is not zipped. In the Terminal window, type the command:
and press the return key. Then set the execute permissions by typing in the command:
chmod +x OnePlay-V01.rb
and press the return key.
Then open the script in a text editor (Big NOTE: you must have smart quotes etc, turned OFF or else very bad things will happen; the earth will open up and dragons will carry your machine back into the bowels of a volcano or something like that will happen) and enter the full path to some of your songs on your drive. I have not tested this with network attached drives, those might be okay. Use a locally attached drive just to be safe. You can only use wav or m4a audio files at this time. This will not play your flac files . I listed five song placeholders, uncomment the line with the song you wish to use by removing the # character from the front of the line. Save the file. Then in Terminal type in the command:
and press the return key.
The script will tell you some information about your chosen song, then list the audio output options you have available, letting you choose one and then letting you choose from the available rates to play the song. And then it will play the song. Or, at least that is what is supposed to happen.
I have found that the standard audio out devices play without incident, in that the song will play at the rate you choose. So the CoreAudio stuff is working correctly. Things get strange in choosing the audio output(s) via the RX 4nn card connectors. As you know, the song will not play at the correct speed, but if you choose different playback speeds, your connected equipment will do just as you tell it, by playing the wrong-speed song back at the chosen rate. Try it and you will see what I am referring to. Now, if you try to play back to a a/v receiver via the HDMI connector, you will most likely get an error. The script will tell you the dim of the header does not contain the information about the number of channels. If you use the audio midi setup app, (found in the Applications/Utilities folder) you can set the HDMI output to be two channel type of output which will cause the error to go away, but the audio will still be silent while the song continues to play.
So, the core audio stuff is working properly, but it seems the 9510 controller or the 4100 kext is intercepting the output, and mixing it with the video signal but not giving the proper header to the receiver so it can decode the signal.
errors. errors. errors.