how to control the output device of soundsc?
29 views (last 30 days)
Show older comments
Tom Shlomo on 30 Jan 2020
Answered: Jamie Haas on 27 Mar 2023
When I use soundsc to play an audio signal, the audio is played through the speakers, even when the headphones are connected.
Other MATLAB sounds (such as errors) are played through the headphones.
How can I get soundsc to use the headphones?
(I recently moved from windows to mac. In windows it was no problem as soundsc used the output device defined by the operating system)
Jamie Haas on 27 Mar 2023
This can happen when you plug in headphones after Matlab has been launched.
Running the following command worked for me:
You can see the list of devices that matlab sees by running:
info = audiodevinfo
and then viewing the struct returned to info variable.
Find more on Audio I/O and Waveform Generation in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!