Main Content


Stop transmission from preamble detector



stopTransmission(pd) stops continuous IQ waveform transmission to the air from the preamble detector pd.


collapse all

Configure a preamble detector to continuously send a test waveform with a known preamble sequence and capture data samples of the transmitted waveform.

Define a preamble sequence with good correlation properties. For example, generate and normalize a Zadoff-Chu sequence of length 137.

seq = zadoffChuSeq(38,137);
preamble = seq/norm(seq,2); 

Generate a test waveform.

prePadding = complex(zeros(999,1),zeros(999,1));                  
postPadding = complex(zeros(1000,1),zeros(1000,1));               
testWaveform = [prePadding;preamble;postPadding;]; 

Create and configure a preamble detector object, specifying a radio setup configuration previously saved in the Radio Setup wizard.

pd = preambleDetector("MyRadio")
pd = 
  preambleDetector with properties:

            CenterFrequency: 2.4000e+09
                  RadioGain: 10
                   Antennas: "RF0:RX2"
                 SampleRate: 250000000
            CaptureDataType: "int16"
       DroppedSamplesAction: "error"
                   Preamble: 0
            ThresholdMethod: "adaptive"
             FixedThreshold: 0
    AdaptiveThresholdOffset: 0
      AdaptiveThresholdGain: 0
              TriggerOffset: 0

pd.SampleRate = 10.24e6;

Specify the preamble.

pd.Preamble = preamble; 

Send the test waveform continuously.

transmit(pd,testWaveform,"continuous", ...
    TransmitGain=40, ...
    TransmitCenterFrequency=2.45e9, ...

Capture 10 ms of data of the transmitted waveform.

[data,timestamp,droppedSamples,status] = capture(pd,milliseconds(10),seconds(1));

Stop test waveform transmission.


Input Arguments

collapse all

Preamble detector, specified as a preambleDetector object.


The first object function call in which you specify this object as an input requires a few extra seconds to load the application onto the hardware.

Version History

Introduced in R2022a

See Also