1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-11-23 08:28:36 -05:00
sdrangel/plugins/channelrx/udpsrc
2017-09-18 13:41:08 +02:00
..
CMakeLists.txt Channel plugins: Removed useless link dependency on QT OpenGL and Multimedia 2016-10-27 08:46:06 +02:00
readme.md Updated documentation (2) 2017-08-27 17:20:35 +02:00
udpsrc.cpp UDP source plugin: use channel marker address and port 2017-08-25 12:12:46 +02:00
udpsrc.h UDP source plugin: use channel marker address and port 2017-08-25 12:12:46 +02:00
udpsrc.pro Windows build: corrections for the new tool chain 2017-09-18 13:41:08 +02:00
udpsrcgui.cpp UDP sink: save channel marker center frequency in only one slot 2017-08-26 21:20:35 +02:00
udpsrcgui.h Implemented GUI input message queue and interface 2017-09-16 22:23:31 +02:00
udpsrcgui.ui UDP sink plugin: implemented a gain input control for real sample input 2017-08-25 15:29:45 +02:00
udpsrcplugin.cpp GUI segregation: renamed PluginGUI interface to PluginInstanceUI 2017-09-03 19:55:00 +02:00
udpsrcplugin.h GUI segregation: renamed PluginGUI interface to PluginInstanceUI 2017-09-03 19:55:00 +02:00

UDP source plugin

Introduction

By "source" one should undetstand a source of samples for the outside of SDRangel application. An UDP connection is established from the plugin to the given address and port and samples are directed to it.

The UDP block size or UDP payload size is fixed at 512 bytes.

The receiving application must make sure it acknowledges this block size. UDP may fragment the block but there will be a point when the last UDP block will fill up a complete block of this amount of bytes. In particular in GNUradio the UDP source block must be configured with a 512 bytes payload size.

This plugin is available for Linux and Mac O/S only.

Interface

UDP Source plugin GUI

1: Frequency shift from center frequency of reception

Use the wheels to adjust the frequency shift in Hz from the center frequency of reception. Left click on a digit sets the cursor position at this digit. Right click on a digit sets all digits on the right to zero. This effectively floors value at the digit position. Wheels are moved with the mousewheel while pointing at the wheel or by selecting the wheel with the left mouse click and using the keyboard arroews. Pressing shift simultanoeusly moves digit by 5 and pressing control moves it by 2.

2: Input channel power

Total power in dB relative to a +/- 1.0 amplitude signal received in the pass band.

3: Output channel power

Total power in dB relative to a +/- 1.0 amplitude signal sent over UDP.

4: UDP address and ports

These parameters are set with the basic channel settings dialog. See: here

The display is in the format address:audio port/data port

5: Signal sample rate

Sample rate in samples per second of the signal that is sent over UDP. The actual byte rate depends on the type of sample which corresponds to a number of bytes per sample.

6: Type of samples

Combo box to specify the type of samples that are sent over UDP.

  • S16LE I/Q: Raw I/Q samples on signed 16 bits integers with Little Endian layout. Use it with software that accepts I/Q data as input like GNUradio with the UDP source block. The output is interleaved I and Q samples
  • S16LE NFM: AF of FM demodulated signal as 16 bits signed integers with Little Endian layout. Use it with software that takes the FM demodulated audio or the discriminator output of a radio as input. Make sure you specify the appropriate signal bandwidth (see 7) according to the AF bandwidth needs. The output is a repetition of NFM samples on real part and on imaginary part this facilitates integration wtih software expecting a stereo type of input with the same samples on L and R channels. With GNURadio just use a complex to real block.
  • S16LE NFM Mono: This is the same as above but only one sample is output for one NFM sample. This can be used with software that accept a mono type of input like dsd or multimon.
  • S16LE USB: AF of USB demodulated signal as 16 bits signed integers with Little Endian layout. Use it with software that uses a SSB demodulated signal as input i.e. software that is based on the audio output of a SSB radio. The output is the I/Q binaural output of the demodulator.
  • S16LE LSB: AF of LSB demodulated signal as 16 bits signed integers with Little Endian layout. Use it with software that uses a SSB demodulated signal as input i.e. software that is based on the audio output of a SSB radio. The output is the I/Q binaural output of the demodulator.
  • S16LE LSB Mono: AF of the LSB part of a SSB demodulated signal as "mono" (I+Q)*0.7 samples that is one sample per demodulator output sample. This can be used with software that accepts mono type of input.
  • S16LE USB Mono: AF of the USB part of a SSB demodulated signal as "mono" (I+Q)*0.7 samples that is one sample per demodulator output sample. This can be used with software that accepts mono type of input.
  • S16LE AM Mono: AF of the enveloppe demodulated signal i.e. channel magnitude or sqrt(I² + Q²) as "mono" samples that is one sample per demodulator output sample. This can be used with software that accepts mono type of input.
  • S16LE AM !DC Mono: Same as above but with a DC block based on magnitude average over a 5 ms period
  • S16LE AM BPF Mono: Same as AM Mono but raw magnitude signal is passed through a bandpass filter with lower cutoff at 300 Hz and higher cutoff at RF bandwidth frequency

7: Signal bandwidth

The signal is bandpass filtered to this bandwidth (zero frequency centered) before being sent out as raw I/Q samples or before being demodulated for SSB and FM outputs. Thus a 20000 Hz bandwidth for example means +/-10000 Hz around center channel frequency.

When SSB formats are used only the lower half (LSB) or upper half (USB) of the bandwidth is used. Thus to pass SSB over 3000 Hz bandwidth one should set this signal bandwidth to 6000 Hz.

8: FM deviation

This is the maximum expected FM deviation in Hz for NFM demodulated samples. Therefore it is active only for NFM types of sample formats. A positive deviation of this amount from the central carrier will result in a sample output value of 32767 (0x7FFF) corresponding to a +1.0 real value. A negative deviation of this amount from the central carrier will result in a sample output value of -32768 (0x8000) corresponding to a -1.0 real value.

9: AGC and audio feedback control

UDP Source plugin GUI AGC

9.1: Toggle AGC

It is effective only for AM and SSB. Signal is normalized to +/- 0.5 times the maximum amplitude with a time constant (averaging) of 200 ms. When engaged the squelch gate is fixed at 50 ms. The release time controlled by (15.3) can be increased from the 50 ms default for SSB signals to prevent accidental signal drops due to drops in the voice.

9.2: Toggle audio feedback

This turns on or off the audio samples feedback

9.3: Mono/Stereo toggle for audio feedback

This toggles between mono or stereo audio feedback

10: Apply (validation) button

The changes in the following items only become effective when this button is pressed:

  • Samples format (4)
  • Output sample rate (5)
  • Address (6)
  • RF bandwidth (7)
  • Data port (8)
  • Audio port (9)
  • FM deviation (11)

When any item of these items is changed the button is lit in green until it is pressed.

11: Audio volume

Volume of the audio feedback (when se with button 12.2).

12: Gain

This gain is applied to the samples just before they are sent via UDP. The gain value appears at the right of the slider.

13: Squelch

UDP Source plugin GUI Squelch

13.1: Squelch indicator

The background of the "Sq" text is lit in green when the squelch is open

13.2: Squelch level

Use the slider to set the squelch power threshold based on channel input power (2). At the right of the slider the value in dB is displayed

13.2: Squelch gate

Sets the delay after which a signal constantly above the squelch threshold effectively opens the squelch. The same delay is used for squelch release except for SSB where the gate is fixed at 50 ms and this controls the release time only.

The delay in milliseconds is displayed at the right of the button.

14: Spectrum display

This is the spectrum display of the channel signal after bandpass filtering. Please refer to the Spectrum display description for details.

This spectrum is centered on the center frequency of the channel (center frequency of reception + channel shift) and is that of a complex signal i.e. there are positive and negative frequencies. The width of the spectrum is proportional of the sample rate. That is for a sample rate of S samples per seconds the spectrum spans from -S/2 to +S/2 Hz.