Author Topic: Hotkey to switch microphones?  (Read 1894 times)

Glaintha

  • Newbie
  • *
  • Posts: 3
Hotkey to switch microphones?
« on: February 05, 2022, 11:41:05 PM »
First of all, as a disabled person VoiceAttack has made my life so much easier and I'm so thankful.

I've been using a USB microphone but I have to change positions to help with the blood flow and when I change positions, the mic cannot hear my voice well enough because I have to be further away.

So I bought a wireless headset (bluetooth doesn't support audio and mic at the same time) and its mic works like a charm with VA. I didn't even have to redo the speech recogniton training or create a new profile. The headset is Steelseries Arctis 1 Wireless btw.

So my question is, is there an easier way to change the recording device in VA without going into the settings menu? I've searched the forum a lot but couldn't find a topic that answers this. Is manually changing it via the menu the only way to switch mics?

Pfeil

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 4786
  • RTFM
Re: Hotkey to switch microphones?
« Reply #1 on: February 06, 2022, 07:14:32 AM »
When you use the "Change Default Audio Devices" action to change the Windows default recording device, provided that the "Windows Speech Recording Device" option on the "Recognition" tab of the VoiceAttack options window is set to the "Default - "-prefixed option, VoiceAttack should automatically restart the speech recognition engine to switch devices to the new default recording device.

To toggle between two devices, you could use a condition and the "{STATE_DEFAULTRECORDING}" token to check which device is currently active.

SemlerPDX

  • Global Moderator
  • Sr. Member
  • *****
  • Posts: 291
  • Upstanding Lunatic
    • My AVCS Homepage
Re: Hotkey to switch microphones?
« Reply #2 on: February 06, 2022, 07:35:31 PM »
First of all, as a disabled person VoiceAttack has made my life so much easier and I'm so thankful.

Same here - stuck at home, and swap between an area mic and headset mic using a voice command.

If you are super new, and need just a peek at what making a condition and using a token like that might look like, this may help you and others get a leg up and head start on making conditional commands for switching a microphone.

Here's how I set up my command to do that:


Under the "Text" tab along the top, we enter the token up top, and the text we want to compare in the Text field:


Conditions have options, and sometimes it can be more simple to select 'Contains' for something like this (if there are no other recording devices named with this same keyword)




(Either of these would work equally well, just wanted to highlight the options and ways to use both)


We end up with a 'Begin Text Compare' condition that looks like this - then we select 'Other' to add the action to change audio device:



Selecting the "multimedia recording device" to the one you want - this action is also a great place to quickly peek at your device names while building this command, for use in the condition above:


Next we can add an "Else" condition so that when we call this command (using my devices in this example) if the Logitech headset mic is active, it switches to the hands free mic, else if not, it switches to the Logitech mic:



(then, of course, just copy or duplicate the 'Change audio device' action and set it to the other mic)

In the end, we'll have a command that might look just like this - adjusting the 'When I say' phrase as you want, adding your own description and/or category name to keep your profile organized.




If you want this on a hotkey instead of voice command, just click on the checkbox next to the keys/buttons/mouse to set one of these up with a hotkey to call this command:





Hope the pics help - I was bored and I remember when I was brand new to VoiceAttack to the point where I didn't even know certain advanced actions existed, let alone all the fancy tokens and how to properly make use of them when someone like Pfeil would suggest them to me.

Cheers!
« Last Edit: April 16, 2022, 11:29:54 AM by SemlerPDX »

Glaintha

  • Newbie
  • *
  • Posts: 3
Re: Hotkey to switch microphones?
« Reply #3 on: February 07, 2022, 03:00:21 AM »
Wow thank you! This looks so helpful yet so alien to me since I've never tried something like this before but now I'll definitely give it my best. I believe I can do it since you described it with detail.

I'm not so new to VA but the default commands were enough for my needs up until now. Having another option for switching mics will be nice.

Thanks again, very much appreciated :)