Analog Audio Input use as source of WSPR-decoding

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

Analog Audio Input use as source of WSPR-decoding

Ulli
Hi,
Although once asked here on the forum, it is still not clear to me, how to use analog audio at the audio Input of your Computer as a source for WSPR decoding using WD

I have a Laptop with Ubuntu
I also have the line-out of a receiver, which gives me analog audio.
I have plugged a physical audio cable from the receiver to the mic input of  my laptop - I can see the audio is detected by the computer.

Now what to do ?

I configured in .conf file:

"AUDIO_0    localhost: 0,0    ON5KQ   JO10os   NULL"

then used this audio input to do the processing for 40m decoding...

However:
In the terminal window of my laptop (starting with ./wsprdaemon.sh -a and then ./wsprdaemon.sh -i) it keeps scrolling with a warning 'ALSA underrun...' ..it scolls that fast, that I can't read more than that....

What is fundamentally wrong here ?

I don't see any WAV file recording - however it seems it crashes the audio or does nothing ?
How can I find out which parameters/adresses are correct for my external microphone input at this HP-laptop ?  (localhost x,x numbers)

Can't I use external analog audio input like this with this laptop - how do I find out and solve the error ?

Many thanks for some suggestions.

Ulli, ON5KQ
Reply | Threaded
Open this post in threaded view
|

Re: Analog Audio Input use as source of WSPR-decoding

Ulli
I managed that Wavefiles are written, finally with this HP laptop from its Analog audio input
Also I checked the WSPRD decoder is starting after the first full 2min of wave file recording (5.2Mb of stereo!)

However monitoring any upload file, I found nothing is been found to be uploaded in the recordings...

Fundamental question:
I run the latest regular WD version 2.9j
Is there a fix implemented to handle stereo recordings correctly or is there a procedere how to handle these files ?

Many thanks for info

Ulli, ON5KQ
Reply | Threaded
Open this post in threaded view
|

Re: Analog Audio Input use as source of WSPR-decoding

Gwyn
Administrator
In reply to this post by Ulli
Hello Ulli

 This is one for Rob only I'm afraid.
What I do know is that he provided a simple fix in response to a very similar issue, on this forum under topic
 
AUDIO_ RX on WD by renebir

which if I remember correctly added a flag in the conf file for audio, but I agree, I cannot see it in version 2.9j on Github

best wishes

Gwyn

Reply | Threaded
Open this post in threaded view
|

Re: Analog Audio Input use as source of WSPR-decoding

Ulli
Thanks Gwyn for reply,
I can see the SoX command while recording in the TOP window. I cannot see anything in the SoX command options in what is shown in TOP-terminal, which shows a conversion from stereo to mono, before recording. That's why my Wav-filesize is 5.2Mb (same issue than other forum topic)....

I was wondering, if this issue was solved with latest WD-version...

It is hard to change the recording process of the laptop, as it has no controls to switch between Stereo and Mono-recording.

Ulli, ON5KQ
Reply | Threaded
Open this post in threaded view
|

Re: Analog Audio Input use as source of WSPR-decoding

Ulli
I can see the SoX command in the TOP-terminal. As I know my Wave-files are 5.2Mb (stereo) SoX needs to convert the Stereo file (two channels) into one channel (Mono) before writing the Wav-file

SoX command options offer the parameter "-c" for the number of channels.
So in my case the actual SoX command should be extended with the parameter "-c1", which I don't see now in the actual SoX command of the TOP-terminal, when Wsprdaemon is running on the Laptop

So - where in the whole file structure of WD is this SoX-command executed, so the parameter -c1 can be added in the software-code for guiding SoX to convert to single channel (mono) before writing Wav-files ?
Perhaps it is a good idea in any case to force SoX to only write a single channel Wav-file - so implement it in the WD-code anyway...

Is my analysis of this problem correct ? So where is that code line to change ? Any implications to other stuff in the software ?

Ulli, ON5KQ
Reply | Threaded
Open this post in threaded view
|

Re: Analog Audio Input use as source of WSPR-decoding

Gwyn
Administrator
Hello Ulli
 Your analysis of the problem is correct, and so is the solution - using sox - and that is the approach Rob took.
I'm sure he'll pick this up soon ...

Gwyn
Reply | Threaded
Open this post in threaded view
|

Re: Analog Audio Input use as source of WSPR-decoding

Ulli
In reply to this post by Ulli
I wrote all of this to document what I was doing/analyse...

So, I can report that finally it is working!

I opened the file wsprdaemon.sh in "Geany" to see the code (thanks to open-source software of WD)
Then I searched for the term "sox" in the code and finally found the command which calls "sox" in the audio input section of the code (not in the RTL-SDR section)

In this SOX command I added the parameter "-c 1"  just before "--rate 12k"

Problem solved!
That indeed makes the trick...

Now 40m spots are added from the audio file input from a non-Kiwisdr receiver via the audio input at the laptop.

Interesting:
- In parallel of routing a physical cable to the audio input of the laptop, I stream the audio from the same receiver to WSJT-x on my PC to compare if there are differences in decoding between wsprdaemon and wsjt-x (with version 2.2.2 wsprd decoder)
- to my surprise wsjt-x decodes clearly more spots ! about 10-20% more....

Is there a still a problem with noise ingress (due to bad physical cable connection or audio input noise at the laptop) which accounts for this inferior decoding quality at the laptop ?
To find this out is on the to do list....

Ulli, ON5KQ
Reply | Threaded
Open this post in threaded view
|

Re: Analog Audio Input use as source of WSPR-decoding

Ulli
I readjusted levels carefully and checked the audio cable from the external receiver to the laptop.
As a result, I find no difference in the number of spots nor any difference in SNR values whether it is using wsjt-x or wsprdaemon.

For this test I run both wsjt-x and wsprdaemon at the same time from the same receiver.
-wsprdaemon uses the hardware DAC build-in (audio out connector) the external receiver and a physical audio cable to the laptop
- wsjt-x using Virtual audio cable as input for the software running on PC

The result are as expected..

Note:
The whole desire using the analog input audio as signal source derives from the fact, that I want my real monoband antenna (8ele vertical tx/rx array) implemented. But as this antenna only works on 40m it seems to me rediculous to use an additional kiwi for only one additional input on a single band.

Now, I must re-align the vertical array (8pcs of quarterwave resonant GP's, 8km copperwire radial network, all verticals on a circle of 26.5m (5/8 of the wavelength), equidistant positioned on the circle)

When aligned correctly (using 4-stroke Oscilloscope) the opening of the beam is just above 45deg with F/B and F/Side well above 20db on all frequencies within 40m band (200kHz).

The beam pattern can be switched every 45deg in azimuth instantly and this was a lot of fun for DXing. However it is 10years ago, when I used it last time... so a lot to do, to refurbish .... corroding relais, corroding connectors at the elements, etc.... so work in progres!

Ulli, ON5KQ