Board index FlightGear Development Aircraft

Can you send different sounds to different sound cards?

Questions and discussion about creating aircraft. Flight dynamics, 3d models, cockpits, systems, animation, textures.

Can you send different sounds to different sound cards?

Postby ScottBouch » Fri Jun 17, 2022 10:32 am

Hi all,

Is there a way to detect multiple sound cards (ie: native motherboard, plus USB card) and send the headset/intercom noises such as the TACAN / VOR Morse code to one, and direct the ambient engine noise and other airframe clunks/whirrs etc... to the other card?

This is because I would like to use a real aviation headset with my sim (these are Mono) and only send to it the sounds that would be sent to a headset in the real aircraft, but having speakers set at the sides for the ambient sounds (in stereo).

Of course I'd need some logic where if there is only one sound card present just send everything to that one to suit most people's desktop use too. Maybe a sound settings dialogue box would be better than automating it though so the user has full control over what to send to which card.

Of course its a little further complicated if multiplayer flight uses Teamkspeak or Mumble, getting this to the right sound card too may be an issue.

OR am I into the realm of using my PC to play the NAV headset stuff (Morse codes etc), a raspberry pi set up somehow to play the ambient stuff, and another raspberry pi for multiplayer voice?

(PS, I have had FGFS working well (down-tuned graphics) on a Raspberry Pi 4)

Cheers, Scott
Last edited by ScottBouch on Fri Jun 17, 2022 11:32 am, edited 1 time in total.
User avatar
ScottBouch
 
Posts: 183
Joined: Wed Jun 22, 2016 4:14 pm
Location: Midlands, UK
OS: Linux Mint

Re: Can you send different sounds to different sound cards?

Postby merspieler » Fri Jun 17, 2022 11:30 am

Getting mumble or swift audio to the headset is no issue... just set up your audio properly. (I like pavucontrol for that)
Afaik, there's not way tho, to send the rest of the audio to different outputs or channels. In the audio settings you can only set the output device for everything. Also, there's information missing, on what should go to the headphones... like AP warnings for example, no way of setting that.
Would be a great addition tho.
Nia (you&, she/her)

Please use gender neutral terms when referring to a group of people!

Be the change you wish to see in the world, be an ally to all!

Join the official matrix space
merspieler
 
Posts: 2241
Joined: Thu Oct 26, 2017 11:43 am
Location: Wish to be in YBCS
Pronouns: you&, she/her
Callsign: you&, she/her
IRC name: merspieler
Version: next
OS: NixOS

Re: Can you send different sounds to different sound cards?

Postby ScottBouch » Fri Jun 17, 2022 11:38 am

Thanks for that...

So, there's not a lot I can do at the aircraft model level, it's more of a core FGFS sim issue?

I imagine this as a feature would be something that initially only gets used by people building physical sims, but could also be widely used by a desktop user for a bit more realism... If the other people in the house don't mind the speakers and jet noise!
User avatar
ScottBouch
 
Posts: 183
Joined: Wed Jun 22, 2016 4:14 pm
Location: Midlands, UK
OS: Linux Mint

Re: Can you send different sounds to different sound cards?

Postby wkitty42 » Fri Jun 17, 2022 11:42 am

ScottBouch wrote in Fri Jun 17, 2022 11:38 am:So, there's not a lot I can do at the aircraft model level, it's more of a core FGFS sim issue?

yes and yes...
"You get more air close to the ground," said Angalo. "I read that in a book. You get lots of air low down, and not much when you go up."
"Why not?" said Gurder.
"Dunno. It's frightened of heights, I guess."
User avatar
wkitty42
 
Posts: 9146
Joined: Fri Feb 20, 2015 4:46 pm
Location: central NC, USA
Callsign: wk42
Version: git next
OS: Kubuntu 20.04

Re: Can you send different sounds to different sound cards?

Postby ScottBouch » Fri Jun 17, 2022 12:04 pm

Ok, so as a workaround...

In the Lightning, the only aircraft generated sounds are the Morse codes from the TACAN and the marker sounds of the ILS (and historically the Head Sound Reproducer used for Data Link remote flight control), plus audio warning clangers.

As the NAV sounds are just tones they could be generated by an Arduino easily to be mixed into headset audio with good old analogue electronics, if there is a Bool property in the NAV part of the property tree that changes state when the Morse tones start / stop, this can be used to turn the tone generator on/off. If this bool doesn't exist, then it's not so easy.

I also have recordings of the background hum of the radio and intercom system, plus the clicks and pops heard through the headset when U/VHF frequencies are changed, and the change in in hum when PTT is pressed. I guess I could save these to a raspberry pi and get into some Python scripting to play them when properties are changed in the tree.. this would mean accessing the property tree by Ethernet though, and really brushing up on Python.
User avatar
ScottBouch
 
Posts: 183
Joined: Wed Jun 22, 2016 4:14 pm
Location: Midlands, UK
OS: Linux Mint


Re: Can you send different sounds to different sound cards?

Postby merspieler » Fri Jun 17, 2022 9:31 pm

Yes, using external scripts could solve that... then you don't even need the raspberry pi... you could just run it on your pc and direct your scripts audio to a different device than FGs
Nia (you&, she/her)

Please use gender neutral terms when referring to a group of people!

Be the change you wish to see in the world, be an ally to all!

Join the official matrix space
merspieler
 
Posts: 2241
Joined: Thu Oct 26, 2017 11:43 am
Location: Wish to be in YBCS
Pronouns: you&, she/her
Callsign: you&, she/her
IRC name: merspieler
Version: next
OS: NixOS

Re: Can you send different sounds to different sound cards?

Postby Hooray » Mon Jun 20, 2022 5:25 pm

That's actually a pretty plausible feature request, and one in line with what home cockpit builders have requested in the past.
In other words, I would definitely suggest to discuss this on the devel mailing list and/or at least file a feature request here: https://sourceforge.net/p/flightgear/codetickets/

The background here being, FlightGear already has pretty sophisticated audio support under the hood, the question is merely if, and how much of, this is exposed to the UI in the form of fgcommands and/or properties.

The main guy when it comes to FlightGear audio is Erik Hofman (erik on the forum), so you could also reach out to him directly.

The other thing is that USB HID support has recently been improved, too.
You will also find home cockpit builders on the devel list, so you could discuss your feature request with like-minded folks there.

Speaking in general, it really sounds like a worthwhile thing to explore - at the very least, you should document the idea, supporting this kind of use-case would also make FG more relevant to professional users.
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 12707
Joined: Tue Mar 25, 2008 9:40 am
Pronouns: THOU


Return to Aircraft

Who is online

Users browsing this forum: No registered users and 11 guests