Test release

This commit is contained in:
Vasiliy Doylov 2024-10-27 23:20:28 +03:00
parent 999cddfdca
commit c51339ef63
Signed by: NekoCWD
GPG key ID: B7BE22D44474A582

View file

@ -25,9 +25,9 @@ string earpiece_mixer;
string card_name;
private const GLib.OptionEntry[] options = {
{ "speaker", 's', OptionFlags.NONE, OptionArg.STRING, ref speaker_mixer, "mixer for speaker mode", "QUAT_MI2S_RX Voice Mixer VoiceMMode1" },
{ "earpiece", 'e', OptionFlags.NONE, OptionArg.STRING, ref earpiece_mixer, "mixer for earpiece mode", "SLIMBUS_0_RX Voice Mixer VoiceMMode1" },
{ "card", 'c', OptionFlags.NONE, OptionArg.STRING, ref card_name, "alsa card", "hw:0" },
{ "speaker", 's', OptionFlags.IN_MAIN, OptionArg.STRING, ref speaker_mixer, "mixer for speaker mode", "QUAT_MI2S_RX Voice Mixer VoiceMMode1" },
{ "earpiece", 'e', OptionFlags.IN_MAIN, OptionArg.STRING, ref earpiece_mixer, "mixer for earpiece mode", "SLIMBUS_0_RX Voice Mixer VoiceMMode1" },
{ "card", 'c', OptionFlags.IN_MAIN, OptionArg.STRING, ref card_name, "alsa card", "hw:0" },
{ null }
};
@ -81,6 +81,9 @@ int main (string[] args) {
printerr ("Run '%s --help' to see a full list of available command line options.\n", args[0]);
return 1;
}
if (speaker_mixer == null || earpiece_mixer == null || card_name == null) {
error ("Run --help to get options. You need to specify card, speaker and earpiece");
}
Alsa.Card card;
message ("Card open: %d", Alsa.Card.open (out card, card_name, Alsa.CardOpenType.NONBLOCK));