https://github.com/ashleymarkfletcher/audio-devices
Switch audio device on Windows
https://github.com/ashleymarkfletcher/audio-devices
audio audio-devices javascript npm-package windows
Last synced: 2 months ago
JSON representation
Switch audio device on Windows
- Host: GitHub
- URL: https://github.com/ashleymarkfletcher/audio-devices
- Owner: ashleymarkfletcher
- Created: 2017-09-19T21:31:13.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2018-01-23T23:54:15.000Z (over 8 years ago)
- Last Synced: 2025-11-23T20:23:18.712Z (8 months ago)
- Topics: audio, audio-devices, javascript, npm-package, windows
- Language: JavaScript
- Size: 45.9 KB
- Stars: 2
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# audio-devices
get and set the current audio device on windows.
[](https://nodei.co/npm/audio-devices/)
[](https://ci.appveyor.com/project/ashleymarkfletcher/audio-devices)
[](https://codecov.io/gh/ashleymarkfletcher/audio-devices)
### Installing
```bash
$ npm install audio-devices --save
```
## Features
* Set the current audio device
* Get a list of all audio devices(WIP!)
## Example Usage
Set the current device to "Speakers"
```js
const audioDevices = require('audio-devices');
audioDevices.setDevice('Speakers')
.then(() => {
console.log('done!')
})
.catch((err) => {
console.log('error', error)
})
```
## ToDo
* Add CLI
* Find alternative to nircmd for getting audio devices
## Known issues
* Getting the list of audio devices opens a popup and isn't readable