FreeDV with PulseAudio support

154 views
Skip to first unread message

Mooneer Salem

unread,
Dec 25, 2021, 2:38:11 AM12/25/21
to digita...@googlegroups.com
Hi all,

I've been working on a version of FreeDV with PulseAudio support over the holiday period so we don't have to continue waiting for PortAudio to support it. Can those of you running Linux give it a shot and let me know how it goes? The following should work on a Debian-based distro, with changes as appropriate for installing PulseAudio libraries on others:

sudo apt install libpulse-dev
cd freedv-gui
git checkout ms-pulseaudio
./build_linux.sh

and to run:

cd build_linux
src/freedv

(If you prefer to build FreeDV without using the build_linux.sh script, just make sure to include -DUSE_PULSEAUDIO=1 in the cmake call. Otherwise, it will continue using PortAudio as before.)

Anyway, please comment here or in the associated pull request (https://github.com/drowe67/freedv-gui/pull/194) if you run into any issues.

Thanks (and Merry Christmas/Happy Holidays),

-Mooneer K6AQ

Richard Shaw

unread,
Dec 25, 2021, 9:19:57 AM12/25/21
to digita...@googlegroups.com
Seemed to work for me fine. I didn't try transmitting or anything but configuring and showing input audio on the waterfall was successful.

Thanks,
Richard
KF5OIM

Brian Morrison

unread,
Dec 25, 2021, 12:24:21 PM12/25/21
to digita...@googlegroups.com
On Sat, 25 Dec 2021 08:19:43 -0600
Richard Shaw <hobbe...@gmail.com> wrote:

> Seemed to work for me fine. I didn't try transmitting or anything but
> configuring and showing input audio on the waterfall was successful.

If you have a look here Richard

https://github.com/drowe67/freedv-gui/pull/194

you can see my comments (as Tyrbiter) about the pavucontrol oddity I'm
seeing on Fedora 35 using pipewire and pipewire-pulse, maybe you could
compare your experience and see if it's something bizarre at my end.

--

Brian G8SEZ

Mooneer Salem

unread,
Dec 25, 2021, 2:16:23 PM12/25/21
to digita...@googlegroups.com
FYI, I pushed some changes into that repo this morning that may or may not help.

Also, since there were significant changes to how audio's handled in general, I'd appreciate if Windows and Mac users can test and make sure nothing broke on those platforms. Prebuilt binaries for those platforms are up at https://www.dropbox.com/sh/hcfdey5o9m14n2k/AACOXutWd88yska77pzHP7uPa?dl=0.

-Mooneer K6AQ

--
You received this message because you are subscribed to the Google Groups "digitalvoice" group.
To unsubscribe from this group and stop receiving emails from it, send an email to digitalvoice...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/digitalvoice/20211225172417.210c5482%40deangelis.fenrir.org.uk.

Brian Morrison

unread,
Dec 25, 2021, 5:14:08 PM12/25/21
to digita...@googlegroups.com
On Sat, 25 Dec 2021 11:16:09 -0800
Mooneer Salem <moo...@gmail.com> wrote:

> FYI, I pushed some changes into that repo this morning that may or may not
> help.

Yes, OK, I saw those. I thought Richard might be a good reviewer as he
also uses Fedora 35.

FYI I am in the process of a reinstall of the pipewire packages after
moving the conf files out of their usual places so that the default
configuration is loaded, I will also do this for wireplumber. Once
that's done I will get the latest git code and try again.

On the bleeding edge... ;-)

--

Brian G8SEZ

Boudewijn (Bob) Tenty

unread,
Dec 25, 2021, 6:03:06 PM12/25/21
to digita...@googlegroups.com

It crashes when I click on start after configuring the audio devices.

OS is Ubuntu 20.04

This is the output of the gdb debugger

(gdb) continue
Continuing.
[New Thread 0x7fc07e53e700 (LWP 25274)]
[New Thread 0x7fc0849c9700 (LWP 25275)]
[New Thread 0x7fc08526e700 (LWP 25276)]
[New Thread 0x7fc057fff700 (LWP 25277)]
[New Thread 0x7fc0577fe700 (LWP 25278)]
[New Thread 0x7fc052ffd700 (LWP 25279)]
[Thread 0x7fc052ffd700 (LWP 25279) exited]
[New Thread 0x7fc052ffd700 (LWP 25280)]

Thread 1 "freedv" received signal SIGSEGV, Segmentation fault.
0x000055de241c2107 in std::swap<std::_Any_data> (__a=..., __b=...) at /usr/include/c++/9/bits/move.h:194
194          __a = _GLIBCXX_MOVE(__b);
(gdb) back full
#0  0x000055de241c2107 in std::swap<std::_Any_data>(std::_Any_data&, std::_Any_data&) (__a=..., __b=...)
    at /usr/include/c++/9/bits/move.h:194
        __tmp =
          {_M_unused = {_M_object = 0x7ffff6c98f90, _M_const_object = 0x7ffff6c98f90, _M_function_pointer = 0x7ffff6c98f90, _M_member_pointer = (void (std::_Undefined_class::*)(std::_Undefined_class * const)) 0x7ffff6c98f90, this adjustment 94412576829504}, _M_pod_data = "\220\217\311\366\377\177\000\000@\260\032$\336U\000"}
#1  0x000055de24201103 in std::function<void (IAudioDevice&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, void*)>::swap(std::function<void (IAudioDevice&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, void*)>&) (this=0x7ffff6c98f60, __x=...) at /usr/include/c++/9/bits/std_function.h:549
#2  0x000055de24200e2d in std::function<void (IAudioDevice&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, void*)>::operator=(std::function<void (IAudioDevice&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, void*)> const&) (this=0xc8, __x=...) at /usr/include/c++/9/bits/std_function.h:464
#3  0x000055de24200cf2 in IAudioDevice::setOnAudioDeviceChanged(std::function<void (IAudioDevice&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, void*)>, void*) (this=0x0, fn=..., state=0x0)
    at /home/boudewijn/DATV/freedv-gui/src/audio/IAudioDevice.cpp:56
#4  0x000055de241a5070 in MainFrame::startRxStream() (this=0x55de24aabc00) at /home/boudewijn/DATV/freedv-gui/src/main.cpp:2028
        failed = 212
        modem_samplerate = 21982
        rxOutFifoSizeSamples = 32767
        engine = std::shared_ptr<IAudioEngine> (use count 2, weak count 0) = {get() = 0x55de24ca02a0}
        soundCard1FifoSizeSamples = 32767
        rxSampleRate = 32767
        m_fifoSize_ms = -154562544
        soundCard2FifoSizeSamples = 605497692
        rxInFifoSizeSamples = -154562512
        errorCallback = {__this = 0x7ffff6c99060}
        src_error = 21982
        __PRETTY_FUNCTION__ = "void MainFrame::startRxStream()"
        __FUNCTION__ = "startRxStream"
#5  0x000055de241a1db5 in MainFrame::OnTogBtnOnOff(wxCommandEvent&) (this=0x55de24aabc00, event=...)
    at /home/boudewijn/DATV/freedv-gui/src/main.cpp:1682
        i = 100
        src_error = 0
        startStop = {static npos = 18446744073709551615, m_impl = L"&Start", m_convertedToChar = {m_str = 0x0, m_len = 0}}
        __PRETTY_FUNCTION__ = "virtual void MainFrame::OnTogBtnOnOff(wxCommandEvent&)"
#6  0x00007fc08bf6c921 in wxEvtHandler::ProcessEventIfMatchesId(wxEventTableEntryBase const&, wxEvtHandler*, wxEvent&) ()
    at /usr/lib/x86_64-linux-gnu/libwx_baseu-3.1.so.3
#7  0x00007fc08bf6cdbe in wxEvtHandler::SearchDynamicEventTable(wxEvent&) () at /usr/lib/x86_64-linux-gnu/libwx_baseu-3.1.so.3
#8  0x00007fc08bf6d144 in wxEvtHandler::TryHereOnly(wxEvent&) () at /usr/lib/x86_64-linux-gnu/libwx_baseu-3.1.so.3
#9  0x00007fc08bf6d1ef in wxEvtHandler::ProcessEventLocally(wxEvent&) () at /usr/lib/x86_64-linux-gnu/libwx_baseu-3.1.so.3
#10 0x00007fc08bf6d2f1 in wxEvtHandler::ProcessEvent(wxEvent&) () at /usr/lib/x86_64-linux-gnu/libwx_baseu-3.1.so.3
#11 0x00007fc08bf6eb2b in wxEvtHandler::SafelyProcessEvent(wxEvent&) () at /usr/lib/x86_64-linux-gnu/libwx_baseu-3.1.so.3
--Type <RET> for more, q to quit, c to continue without paging--
#12 0x00007fc08c43a7a4 in  () at /usr/lib/x86_64-linux-gnu/libwx_gtk3u_core-3.1.so.3
#13 0x00007fc089802802 in g_closure_invoke () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#14 0x00007fc089816814 in  () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#15 0x00007fc089821bbe in g_signal_emit_valist () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#16 0x00007fc0898220f3 in g_signal_emit () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#17 0x00007fc089e202ae in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#18 0x00007fc089e20318 in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#19 0x00007fc089802802 in g_closure_invoke () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#20 0x00007fc089816962 in  () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#21 0x00007fc089821bbe in g_signal_emit_valist () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#22 0x00007fc0898220f3 in g_signal_emit () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#23 0x00007fc089e1e754 in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#24 0x00007fc08a0cfae1 in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#25 0x00007fc089802a56 in  () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#26 0x00007fc089821b48 in g_signal_emit_valist () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#27 0x00007fc0898220f3 in g_signal_emit () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#28 0x00007fc089ee6fcc in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#29 0x00007fc089805c56 in g_cclosure_marshal_VOID__BOXEDv () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#30 0x00007fc089802a56 in  () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#31 0x00007fc089821b48 in g_signal_emit_valist () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#32 0x00007fc0898220f3 in g_signal_emit () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#33 0x00007fc089ee4012 in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#34 0x00007fc089ee565b in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#35 0x00007fc089ee8646 in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#36 0x00007fc089eafbb0 in gtk_event_controller_handle_event () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#37 0x00007fc08a07216d in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#38 0x00007fc08a0c94fb in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#39 0x00007fc089802802 in g_closure_invoke () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#40 0x00007fc089815f96 in  () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#41 0x00007fc08982147d in g_signal_emit_valist () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#42 0x00007fc0898220f3 in g_signal_emit () at /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
#43 0x00007fc08a073c23 in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#44 0x00007fc089f2f128 in  () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#45 0x00007fc089f313db in gtk_main_do_event () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#46 0x00007fc089c19f79 in  () at /usr/lib/x86_64-linux-gnu/libgdk-3.so.0
#47 0x00007fc089c4d106 in  () at /usr/lib/x86_64-linux-gnu/libgdk-3.so.0
#48 0x00007fc08971517d in g_main_context_dispatch () at /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#49 0x00007fc089715400 in  () at /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#50 0x00007fc0897156f3 in g_main_loop_run () at /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#51 0x00007fc089f3037d in gtk_main () at /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
#52 0x00007fc08c374075 in wxGUIEventLoop::DoRun() () at /usr/lib/x86_64-linux-gnu/libwx_gtk3u_core-3.1.so.3
#53 0x00007fc08be134d1 in wxEventLoopBase::Run() () at /usr/lib/x86_64-linux-gnu/libwx_baseu-3.1.so.3
--Type <RET> for more, q to quit, c to continue without paging--
#54 0x00007fc08bddd97a in wxAppConsoleBase::MainLoop() () at /usr/lib/x86_64-linux-gnu/libwx_baseu-3.1.so.3
#55 0x00007fc08be68f1b in wxEntry(int&, wchar_t**) () at /usr/lib/x86_64-linux-gnu/libwx_baseu-3.1.so.3
#56 0x000055de24196c16 in main(int, char**) (argc=1, argv=0x7ffff6c9aec8) at /home/boudewijn/DATV/freedv-gui/src/main.cpp:176
(gdb)

73,

Bob VE3TOK

--
You received this message because you are subscribed to the Google Groups "digitalvoice" group.
To unsubscribe from this group and stop receiving emails from it, send an email to digitalvoice...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/digitalvoice/CAAzDfxN94pvbooT3O8AO-QM9jB0RvELFSq7bnGA2d_oYRNBDYQ%40mail.gmail.com.
-- 

When you change the way you look at things, the things you look at change 

Max Planck

Mooneer Salem

unread,
Dec 25, 2021, 7:10:17 PM12/25/21
to digita...@googlegroups.com
Oops, there were some typos during initialization when I added support for tracking sink/source changes. Pull latest and try again?

-Mooneer K6AQ

Boudewijn (Bob) Tenty

unread,
Dec 26, 2021, 12:30:21 AM12/26/21
to digita...@googlegroups.com
I tried again and this time it is not crashing but something is not right. The digital (700d and all other modes)
signal is going out in bursts when I click the ptt. The same when I look at my microphone signal in the GUI.
Also the waterfall doesn't look right.

Bob VE3TOK 

On 2021-12-25 19:10, Mooneer Salem wrote:
> Oops, there were some typos during initialization when I added support for tracking sink/source changes. Pull latest and try again?
>
> -Mooneer K6AQ
>

Peter Reichelt

unread,
Dec 26, 2021, 5:15:15 AM12/26/21
to digitalvoice
Hi Mooneer

I tried your latest build on a windows machine and at first VB cable was not recognised and then the inbuilt microphone was not identified.

I then tried an earlier version of 6.1 and your latest 6.2 and initially I had issues with VB cable but after a few attempts the older versions  worked normally. At this stage I have not retried the latest build to try and quantify the issue. I got distracted trying to prove that I didn't have an issue with sound devices on the computer! The original error message referred to the virtual cable not being present even though it showed up in the audio setup options.

Peter VK5APR

Mooneer Salem

unread,
Dec 27, 2021, 5:33:35 PM12/27/21
to digita...@googlegroups.com
Hi Peter (and others who are interested),

I have a new build up at https://www.dropbox.com/sh/7bexzi2unuw0zzw/AADigPmDE7veVgF5NxyPZFFBa?dl=0 that will probably fix the issue you're having (as well as crashes on Windows that others have reported). Let me know how that goes.

Thanks,

-Mooneer K6AQ

--
You received this message because you are subscribed to the Google Groups "digitalvoice" group.
To unsubscribe from this group and stop receiving emails from it, send an email to digitalvoice...@googlegroups.com.

Mooneer Salem

unread,
Dec 27, 2021, 5:39:06 PM12/27/21
to digita...@googlegroups.com
Hi Bob,

I'm seeing something similar with the plots in single sound card mode with my Ubuntu VM (running on VMware) but I haven't been able to determine what's going on yet. This only happens if I choose the VM's "alsa_input" device for the radio device and not the output's monitor (or QuiskDigitalOutput when running Quisk). I added a bit more logging to that branch; do you see any timeout messages when transmitting or receiving? 

Additionally, can you try using other PulseAudio applications (such as parecord) with your system's audio devices and let me know if those work okay?

Thanks,

-Mooneer K6AQ

--
You received this message because you are subscribed to the Google Groups "digitalvoice" group.
To unsubscribe from this group and stop receiving emails from it, send an email to digitalvoice...@googlegroups.com.

Peter Reichelt

unread,
Dec 28, 2021, 12:32:13 AM12/28/21
to digitalvoice
Hi Mooner

Results same but different! This time the device complained about is my inbuilt microphone which is visible in the audio setup. I have not been able to get FreeDV to run.
Audio Set up RX - Cable OP (VB-Cable) - Speakers,  Tx - Microphone - Cable IP (VB_Cable).

After pressing Start I get error  message (cant find mic)and then in Audio setup I have RX - Cable OP (VB-Cable) - Cable IP (VB_Cable), Tx- none - none.

At all times the mic is identified as available audio device and can be selected within audio setup.

Peter VK5APR

Mooneer Salem

unread,
Jan 2, 2022, 3:58:50 PMJan 2
to digita...@googlegroups.com
Hi all,

I have new builds up at https://www.dropbox.com/sh/000yx7vmp6fy11v/AAB5jXc0reTjSZ_BbvI96rDga?dl=0 to resolve the issue Peter saw with being able to open certain sound devices on Windows. There are also some additional changes to resolve some other bugs discovered during testing. Let me know if you guys have any questions.

Thanks,

-Mooneer K6AQ

Peter Reichelt

unread,
Jan 2, 2022, 8:52:18 PMJan 2
to digitalvoice
Mooneer

All good, Thanks

PeterVK5APR

Mooneer Salem

unread,
Jan 14, 2022, 12:20:54 PMJan 14
to digita...@googlegroups.com
Hi all,

Some additional issues were found since the last build, which should be fixed on the 2022-01-14 build I genera: https://www.dropbox.com/sh/evbhjxflnpoecds/AAD-wPo3Nf8mTJIrnISnEJFXa?dl=0. This also bumps up the version to 1.7.0. As always, let me know if you have any questions.

Thanks,

-Mooneer K6AQ

Boudewijn (Bob) Tenty

unread,
Jan 15, 2022, 4:55:27 AMJan 15
to digita...@googlegroups.com
Hi Mooneer,

I updated the source here but when I compile it I see ALSA and not PulseAudio devices in the audio config.
(I'm really on branch ms-pulseaudio and 1.7)

Bob

On 2022-01-14 12:20, Mooneer Salem wrote:
> Hi all,
>
> Some additional issues were found since the last build, which should be fixed on the 2022-01-14 build I genera: https://www.dropbox.com/sh/evbhjxflnpoecds/AAD-wPo3Nf8mTJIrnISnEJFXa?dl=0 <https://www.dropbox.com/sh/evbhjxflnpoecds/AAD-wPo3Nf8mTJIrnISnEJFXa?dl=0>. This also bumps up the version to 1.7.0. As always, let me know if you have any questions.
>
> Thanks,
>
> -Mooneer K6AQ
>

Mooneer Salem

unread,
Jan 15, 2022, 1:55:20 PMJan 15
to digita...@googlegroups.com
Hi Bob,

The current head of ms-pulseaudio compiles for PortAudio by default. To use PulseAudio instead, you'll need to pass "pulseaudio" to build_linux.sh, e.g.

$ ./build_linux.sh pulseaudio

This is also mentioned in README.md but please let me know if you have suggestions for improvement in that regard.

Thanks,

-Mooneer K6AQ

--
You received this message because you are subscribed to the Google Groups "digitalvoice" group.
To unsubscribe from this group and stop receiving emails from it, send an email to digitalvoice...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages