Beta release of linHPSDR

User avatar
w-u-2-o
Posts: 1041
Joined: Fri Mar 10, 2017 1:47 pm

Beta release of linHPSDR

Postby w-u-2-o » Thu Jun 07, 2018 5:04 pm

I am shamelessly cross-posting the message below from the mailing lists here. Let the discussion begin!

At HAM RADIO 2018 in Friedrichshafen I gave a presentation at the HPSDR Academy on some new Linux software for HPSDR compatible radios called linHPSDR. Please note that this is not PowerSDR running on Linux but a completely new Linux application.

The Beta release of this software is now available on GitHub at https://github.com/g0orx/linhpsdr. The README.md details the prerequisites and how to build the software. It has been built and tested using Ubuntu 17.10 and 18.04.

The major features of the software are:

Linux specific software
Uses WDSP ported to Linux for the DSP library
Supports both Protocol 1 and Protocol 2
Supports up to 7 receivers depending on the radio
Supports 1 transmitter
Uses PortAudio for local audio input/output at the computer
CAT interface over TCP/IP for each receiver
Easy interface to WSJT-X without using a sound card or cables (WSJT-X.odt and .pdf) on github
Can be interfaced to other applications using rigctl built with Hamlib 3.2.

Current development:

Improved documentation (there is an early document linhpsdr-user.odt and .pdf) on github
PureSignal
Diversity
Remote thin client

Remember this is a Beta release so there will still be some bugs in the code and missing features.

-- John Melton g0orx/n6lyt
User avatar
w-u-2-o
Posts: 1041
Joined: Fri Mar 10, 2017 1:47 pm

Re: Beta release of linHPSDR

Postby w-u-2-o » Thu Jun 07, 2018 5:31 pm

And I'll throw out the first question:

I'm trying to figure out the best way for me to run Linux. Please, no hokey/jokey answers about "get rid of your Windows machine, etc." I require Windows, period, and it's not going away.

The biggest issue is that I have a fabulously powerful and well equipped Windows workstation. Triple 4K monitors, big speakers, fancy audio interface, keyboard, etc. How can I leverage this investment to run both Windows and Linux?

I thought about setting up Hyper-V and running Ubuntu as a VM, but a little research tells me that Linux under Hyper-V cannot interface to audio devices. :roll: That's a show stopper, because I have to be able to process audio to/from the PC. The radio is 40ft away in a rack in the basement.

I've thought about dual boot, but that's a non-starter because I require my Windows ecosystem up and running 24/7.

I have another, older, dual Xeon machine I could build as a Linux box, but I have no easy way for it to share the triple 4K monitors, keyboard, etc.

Virtualbox might be a way to go, some Google'ing shows it may support audio.

Any ideas would be most appreciated.

Thanks,

Scott
n1gp
Posts: 8
Joined: Sun Apr 09, 2017 6:34 pm

Re: Beta release of linHPSDR

Postby n1gp » Thu Jun 07, 2018 7:10 pm

Scott,

I run just the opposite, Linux with a Windows 10 hosted in VirtualBox: https://www.virtualbox.org/

This does allow audio through the VM both ways.

Also you may consider running Linux within a Docker container although I think it is only supported
on Windows 10. A quick search turned this up:

https://blog.docker.com/2017/09/preview-linux-containers-on-windows/


-Rick / N1GP
User avatar
w-u-2-o
Posts: 1041
Joined: Fri Mar 10, 2017 1:47 pm

Re: Beta release of linHPSDR

Postby w-u-2-o » Thu Jun 07, 2018 8:16 pm

Hi Rick,

I just finished installing VirtualBox and Ubuntu on my Win10 super-machine. it plays sounds OK. Not sure about recording sounds, yet. Maximized the Firefox window and now Firefox will crash the machine when started--typical Linux B.S. :roll: May have to uninstall/reinstall Firefox.

Next step is to build linHPSDR and see how that goes.

73!

Scott
User avatar
w-u-2-o
Posts: 1041
Joined: Fri Mar 10, 2017 1:47 pm

Re: Beta release of linHPSDR

Postby w-u-2-o » Thu Jun 07, 2018 8:49 pm

Total failure so far. WDSP and linHPSDR both built with a few warnings, and it ran, did the FFT wisdom thing, and started. Then it found the radio, and connected to it, but it's not moving any data at all.

I'm not saying I didn't complicate this a hair with Virtualbox, but, damn, the web browser worked OK, so what the heck? Why is Linux always this hard?

This is what I see when I run from a terminal window:

Code: Select all

radioserver-linux@radioserverlinux-VirtualBox:~$ linhpsdr
Build: 2018-06-05 Beta
GTK+ version 3.22.30
sysname: Linux
nodename: radioserverlinux-VirtualBox
release: 4.15.0-22-generic
version: #24-Ubuntu SMP Wed May 16 12:15:17 UTC 2018
machine: x86_64
discovery
protocol1_discovery
discover: looking for HPSDR devices on enp0s3
discover: bound to enp0s3
discover_receive_thread
discovery: bytes read -1
discovery: recvfrom socket failed for discover_receive_thread: Resource temporarily unavailable
discovery: exiting discover_receive_thread
discover: exiting discover for enp0s3
discovery found 0 devices
protocol2_discover: looking for HPSDR devices on enp0s3
protocol2_discover: bound to enp0s3 10.0.2.15 255.255.255.0
protocol2_disovery: thread_id=0x557259169680
protocol2_discover: received 60 bytes
protocol2_discover: found 0 protocol=1 device=5 software_version=20 status=2 address=10.0.2.2 (00:04:A3:8D:86:6C) on enp0s3
protocol2_discover: bytes read -1
protocol2_discover: recvfrom socket failed for discover_receive_thread: Resource temporarily unavailable
protocol2_discover: exiting protocol2_discover_receive_thread
protocol2_discover: exiting discover for enp0s3
protocol2_discovery found 1 devices
discovery: found protocol=1 device=5 software_version=20 status=2 address=10.0.2.2 (00:04:A3:8D:86:6C) on enp0s3
main: discovery found 1 devices
adding Orion2
tree_selection_changed_cb
found 0
starting Linux HPSDR (Beta): Orion2 P2 v2.0 10.0.2.2 (00:04:A3:8D:86:6C) on enp0s3
create_radio for Orion2 5 10.0.2.2
loadProperties: /home/radioserver-linux/.local/share/linhpsdr/00-04-A3-8D-86-6C.props
create_receiver: channel=0 sample_rate=192000
create_receiver: OpenChannel: channel=0 buffer_size=1024 sample_rate=192000
receiver_update_title: Linux HPSDR: Rx-0 ADC-0 192000
create_vfo: rx=0
iq_thread: channel=0 thread=0x7f96c4005f20
sendto socket failed for general: seq=0
sendto socket failed for receive_specific: sequence=0
sendto socket failed for general: seq=1
sendto socket failed for receive_specific: sequence=1
create_transmitter: channel=8
iq_thread: rx=0 ddc=0
transmitter_init_analyzer: width=0 pixels=0
update_timer: fps=10
protocol2_init: MIC_SAMPLES=64
command_response_thread: id=0x557258f57800
high_priority_thread: id=0x5572590d0a80
mic_line_thread: id=0x5572590d08f0
iq_thread: channel=0 thread=0x5572590d0a30
sendto socket failed for general: seq=2
sendto socket failed for receive_specific: sequence=2
protocol2_thread: date_socket 10 bound to interface
protocol2_thread: high_priority_addr setup for port 1027
protocol2_thread: id=0x5572590d0ad0
tx_panadapter_configure_event: width=1 height=1
protocol2_thread
protocol2_timer_thread: id=0x7f96ac001400
iq_thread: rx=0 ddc=0
mic_line_thread
transmitter_init_analyzer: width=1 pixels=12
SetAnalyzer id=8 buffer_size=4096 overlap=3392
Server listening on port 50000
high_priority_thread
protocol2_timer_thread
command_response_thread
x=217 y=66
moving main_window to x=217 y=66
audio: state_cb: PA_CONTEXT_AUTHORIZING
audio: state_cb: PA_CONTEXT_SETTING_NAME
audio: state_cb: PA_CONTEXT_READY
Output: 0: alsa_output.pci-0000_00_05.0.analog-stereo (Built-in Audio Analog Stereo)
Input: 0: alsa_output.pci-0000_00_05.0.analog-stereo.monitor (Monitor of Built-in Audio Analog Stereo)
Input: 1: alsa_input.pci-0000_00_05.0.analog-stereo (Built-in Audio Analog Stereo)
tx_panadapter_configure_event: width=300 height=165
transmitter_init_analyzer: width=300 pixels=3600
SetAnalyzer id=8 buffer_size=4096 overlap=3392
 
n1gp
Posts: 8
Joined: Sun Apr 09, 2017 6:34 pm

Re: Beta release of linHPSDR

Postby n1gp » Thu Jun 07, 2018 9:29 pm

Scott,

Sorry your having issues. Your startup looks very similar to mine (copied below).
I see nothing that stands out.

I usually setup the network interface in VirtualBox to be a 'bridged' adapter, just in case
you haven't and that may help.

You could put a Protocol 1 FW on it and try this version of cuSDR: https://github.com/n1gp/cudaSDR
just to see if it will pass data (although you'll need to install the QT5 development suite)


$ ./linhpsdr
Build: 2018-06-05 Beta
GTK+ version 3.22.29
sysname: Linux
nodename: n1gp
release: 4.16.0-1-amd64
version: #1 SMP Debian 4.16.5-1 (2018-04-29)
machine: x86_64
Warning: failed to set icon for main_window: /usr/share/linhpsdr/hpsdr.png
Failed to open file '/usr/share/linhpsdr/hpsdr.png': No such file or directory
discovery
protocol1_discovery
discover: looking for HPSDR devices on eth0
discover: bound to eth0
discover_receive_thread
discovery: bytes read -1
discovery: recvfrom socket failed for discover_receive_thread: Resource temporarily unavailable
discovery: exiting discover_receive_thread
discover: exiting discover for eth0
discovery found 0 devices
protocol2_discover: looking for HPSDR devices on eth0
protocol2_discover: bound to eth0 192.168.1.2 255.255.255.0
protocol2_disovery: thread_id=0x5648409cfad0
protocol2_discover: received 60 bytes
protocol2_discover: found 0 protocol=1 device=5 software_version=20 status=2 address=192.168.1.11 (54:10:EC:22:23:C5) on eth0
protocol2_discover: bytes read -1
protocol2_discover: recvfrom socket failed for discover_receive_thread: Resource temporarily unavailable
protocol2_discover: exiting protocol2_discover_receive_thread
protocol2_discover: exiting discover for eth0
protocol2_discovery found 1 devices
discovery: found protocol=1 device=5 software_version=20 status=2 address=192.168.1.11 (54:10:EC:22:23:C5) on eth0
main: discovery found 1 devices
adding Orion2
tree_selection_changed_cb
found 0
starting Linux HPSDR (Beta): Orion2 P2 v2.0 192.168.1.11 (54:10:EC:22:23:C5) on eth0
create_radio for Orion2 5 192.168.1.11
loadProperties: /home/mh/.local/share/linhpsdr/54-10-EC-22-23-C5.props
loadProperties: version=0.000000 expected version=2.000000 ignoring
create_receiver: channel=0 sample_rate=192000
create_receiver: OpenChannel: channel=0 buffer_size=1024 sample_rate=192000
receiver_update_title: Linux HPSDR: Rx-0 ADC-0 192000
create_vfo: rx=0
iq_thread: channel=0 thread=0x56484078c0f0
sendto socket failed for general: seq=0
sendto socket failed for receive_specific: sequence=0
sendto socket failed for general: seq=1
sendto socket failed for receive_specific: sequence=1
create_transmitter: channel=8
iq_thread: rx=0 ddc=0
transmitter_init_analyzer: width=0 pixels=0
update_timer: fps=10
protocol2_init: MIC_SAMPLES=64
command_response_thread: id=0x5648409cced0
high_priority_thread: id=0x5648409ccde0
mic_line_thread: id=0x5648409ccca0
iq_thread: channel=0 thread=0x5648409cfa80
sendto socket failed for general: seq=2
sendto socket failed for receive_specific: sequence=2
protocol2_thread: date_socket 10 bound to interface
protocol2_thread: high_priority_addr setup for port 1027
high_priority_thread
protocol2_thread: id=0x564840a23b20
iq_thread: rx=0 ddc=0
mic_line_thread
command_response_thread
protocol2_thread
protocol2_timer_thread: id=0x7f3500001400
protocol2_timer_thread
Server listening on port 50000
tx_panadapter_configure_event: width=1 height=1
transmitter_init_analyzer: width=1 pixels=12
SetAnalyzer id=8 buffer_size=4096 overlap=3392
protocol2_thread: Unknown port 0
x=-1 y=-1
audio: state_cb: PA_CONTEXT_AUTHORIZING
audio: state_cb: PA_CONTEXT_SETTING_NAME
audio: state_cb: PA_CONTEXT_READY
Output: 0: alsa_output.pci-0000_08_00.1.hdmi-stereo-extra1 (GM204 High Definition Audio Controller Digital Stereo (HDMI 2))
Output: 1: alsa_output.pci-0000_0a_00.3.iec958-stereo (Family 17h (Models 00h-0fh) HD Audio Controller Digital Stereo (IEC958))
Output: 2: combined (Simultaneous output to GM204 High Definition Audio Controller Digital Stereo (HDMI 2), Family 17h (Models 00h-0fh) HD Audio Controller Digital Stereo (IEC958))
Input: 0: alsa_output.pci-0000_08_00.1.hdmi-stereo-extra1.monitor (Monitor of GM204 High Definition Audio Controller Digital Stereo (HDMI 2))
Input: 1: alsa_output.pci-0000_0a_00.3.iec958-stereo.monitor (Monitor of Family 17h (Models 00h-0fh) HD Audio Controller Digital Stereo (IEC958))
Input: 2: alsa_input.pci-0000_0a_00.3.analog-stereo (Family 17h (Models 00h-0fh) HD Audio Controller Analog Stereo)
Input: 3: combined.monitor (Monitor Source of Simultaneous output to GM204 High Definition Audio Controller Digital Stereo (HDMI 2), Family 17h (Models 00h-0fh) HD Audio Controller Digital Stereo (IEC958))
tx_panadapter_configure_event: width=300 height=210
transmitter_init_analyzer: width=300 pixels=3600
SetAnalyzer id=8 buffer_size=4096 overlap=3392
User avatar
w-u-2-o
Posts: 1041
Joined: Fri Mar 10, 2017 1:47 pm

Re: Beta release of linHPSDR

Postby w-u-2-o » Thu Jun 07, 2018 10:08 pm

Bridge mode did the trick, Rick, brilliant! Thank you!

Now the next problem is to get volume levels to be much, much louder. Windows mixer is max'd. Everything is max'd in linHPSDR, the Ubuntu desktop and alsamixer. Not sure how to get things louder.

AGC gain doesn't seem to do anything, and AGC pumping is severe.

73!

Scott
n1gp
Posts: 8
Joined: Sun Apr 09, 2017 6:34 pm

Re: Beta release of linHPSDR

Postby n1gp » Thu Jun 07, 2018 11:49 pm

Scott,

I notice the same here, even running on bare Linux.

Strong signals get very high volume, you then adjust to compensate but then mid to low
level signals are very weak in volume.

I should try playing with the audio/filter configuration...

-Rick / N1GP
User avatar
w-u-2-o
Posts: 1041
Joined: Fri Mar 10, 2017 1:47 pm

Re: Beta release of linHPSDR

Postby w-u-2-o » Fri Jun 08, 2018 1:28 am

Hi Rick,

Thanks for confirming the behavior I'm seeing here.

73!

Scott
Joe-W4WT
Posts: 41
Joined: Sun Apr 09, 2017 5:27 pm
Location: Cumming, GA

Re: Beta release of linHPSDR

Postby Joe-W4WT » Fri Jun 08, 2018 6:41 pm

Current development:

Improved documentation (there is an early document linhpsdr-user.odt and .pdf) on github
PureSignal
Diversity
Remote thin client


I think the "thin client" option that is yet to come might be the best option. It is what I'm planning to use depending on implementation.

Joe W4WT
User avatar
w-u-2-o
Posts: 1041
Joined: Fri Mar 10, 2017 1:47 pm

Re: Beta release of linHPSDR

Postby w-u-2-o » Fri Jun 08, 2018 10:51 pm

Yes, but will it be a Windows client or a Linux client? That makes a big difference to me. I only have Windows and Android when on the road. I dare say most others are in the same boat, perhaps with iOS instead.

More importantly, when will it achieve parity with the PowerSDR feature set? I won't use it as a "daily driver" until it reaches some minimum level of functionality. Not having all of the audio goodies, from phase rotator to ALC, is a show stopper for me, plus a laundry list of other stuff, like programmable filter presets and squelch.

I realize, of course, that this is just the beginning, so patience is the watchword. But I worry that development will peter out well before it reaches a level of maturity commensurate with PowerSDR.
Joe-W4WT
Posts: 41
Joined: Sun Apr 09, 2017 5:27 pm
Location: Cumming, GA

Re: Beta release of linHPSDR

Postby Joe-W4WT » Sat Jun 09, 2018 2:44 am

Scott, I don't see why the "thin client" can't simply be a browser which means it is available regardless of operating system. That makes the most sense to me.

Joe W4WT
User avatar
w-u-2-o
Posts: 1041
Joined: Fri Mar 10, 2017 1:47 pm

Re: Beta release of linHPSDR

Postby w-u-2-o » Sat Jun 09, 2018 2:36 pm

It's definitely an option for the developers, Joe. However, web apps suffer from speed (think spectral display) and UI (knobs, sliders, buttons, etc.) design restrictions, and also are limited in how they can interact with the hardware platform, i.e. moving audio might be difficult.

It seems very likely that the first client app will be for straight shot Linux, as that is what the primary developer (only developer?) is comfortable with.

73,

Scott
w5rcq
Posts: 7
Joined: Mon Apr 10, 2017 3:51 am

Re: Beta release of linHPSDR

Postby w5rcq » Thu Jun 14, 2018 4:57 pm

This is probably a really dumb question, but would this run on a raspberry pi 3B+. The Raspberry pi page says that it will run Ubuntu but I don't know how well it runs it. I am very interested in running my 200D on FT-8 without a bunch of external cables and add-ons. I have the Raspberry pi 3 mounted with a 7 in display and using the keyboard and the mouse. It makes a nice small package. I am not much of a programmer but I have muddled my way through a couple of Linux based projects and am willing to tackle another.
73 Jerry W5RCQ
WZ2Q
Posts: 3
Joined: Fri May 05, 2017 2:53 pm

Re: Beta release of linHPSDR

Postby WZ2Q » Sat Jun 16, 2018 4:19 pm

I was able to get Linhpsdr running under with Windows Subsystem for Linux on Windows 10. Here are the steps I followed:

https://docs.google.com/document/d/e/2PACX-1vRlI6l1zCQJnkPb5k5e16noZbcL8MCi9P20Zko69Dsgp5KNt0iGb9Qx7cDX6W823J5izL3UWQBPlxcq/pub
User avatar
w-u-2-o
Posts: 1041
Joined: Fri Mar 10, 2017 1:47 pm

Re: Beta release of linHPSDR

Postby w-u-2-o » Sat Jun 16, 2018 7:42 pm

Does local audio work under WSL? Or do I have to connect speakers and mic to the radio? Local audio does work under Virtualbox.
WZ2Q
Posts: 3
Joined: Fri May 05, 2017 2:53 pm

Re: Beta release of linHPSDR

Postby WZ2Q » Mon Jun 18, 2018 5:45 am

No local audio under WSL from what I can tell. I used headphones connected directly to the radio.
User avatar
w-u-2-o
Posts: 1041
Joined: Fri Mar 10, 2017 1:47 pm

Re: Beta release of linHPSDR

Postby w-u-2-o » Mon Jun 18, 2018 10:20 am

That's what I thought, thanks, and why I used Virtualbox.

Return to “linHPSDR”