Skip to content

Instantly share code, notes, and snippets.

@JayKickliter
Created April 2, 2014 22:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save JayKickliter/9944949 to your computer and use it in GitHub Desktop.
Save JayKickliter/9944949 to your computer and use it in GitHub Desktop.
using Radio
using Winston
import DSP: welch_pgram
symbols = pskmod( 100000, 4, 4 )
noise = wgn(length(symbols), 5, "dBm", 50, true)
signal = symbols .+ noise
spectrum = welch_pgram( signal, 100, 50 )
spectrum = fftshift( spectrum )
spectrum = 10*log10( spectrum )
@printf( "Oversampled symbol RMS: %f", rms(symbols) )
display(plot( spectrum ))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment