I have Windows 7 64 Bit Professional Edition on the computer that I built, so there is no asking the manufacturer. I use the built-in sound card with 7.1 and optical outputs. The optical output is connected to a Denon amplifier that controls the speakers.
I have a speaker system connected to the computer through the optical port on my sound card. When I use standard Windows drivers, I only get stereo output, so I installed the Realtek HD audio driver. This gives me surround sound, but it does not tie it to the standard speaker, so when I plug in the headphones and define them as headphones, nothing happens, the sound still goes to the speaker system and nothing to the headphones.
I found that if I disconnect the digital output device in the list of playback devices, the sound is automatically redirected through the headphones. So I tried to find a way to turn this device off or on. I have a programmable keyboard, so I can match a program or script with a spare key, so I'm trying to write a program to check if the device is turned on or off, then change it to whatever it is, i.e. if when turned off and if it is turned on.
I tried to find equipment identifiers that are
1. "HDAUDIO \ FUNC_01 & VEN_10EC & DEV_0888 & SUBSYS_105BA601"
2. "HDAUDIO \ FUNC_01 & VEN_10EC & DEV_0888 & SUBSYS_105BA601 & REV_1000"
I planned to create a batch script package using devcon (command line alternative for device manager) using the code below to disable or enable the device
devcon disable "HDAUDIO\FUNC_01&VEN_10EC&DEV_0888&SUBSYS_105BA601*"
devcon enable "HDAUDIO\FUNC_01&VEN_10EC&DEV_0888&SUBSYS_105BA601*"
However, devcon cannot disconnect these devices because the optical connection is on the sound card, and I can disconnect the entire sound card, which would also disconnect the headphones.
I lost a little what to do now, and I really do not want my brother to play with disconnected devices.
. . , c, - . . , - api - devcon - - , . VB6, VB.NET, VB Script, Java Batch Scripting Powershell C, ++ #.NET.
Dexter