Why do I get the error 'Too many input arguments', when executing 'tx(data,fc)'?

8 views (last 30 days)
I set up my SDR transmitter device as follows:
tx = comm.SDRuTransmitter('Platform', 'fooPlatform', ...
'SerialNum','fooSerialNumber', ...
'CenterFrequency',fc, ...
'InterpolationFactor',fooFactor, ...
'MasterClockRate', fooRate,...
'Gain',fooGain);
If 'data' is a sine wave signal, when I use
tx(data, fc)
to transmit the signal, I get the following error:
Too many input arguments. Expected 1 (in addition to System object), got 2.

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 8 Jun 2021
The function call should be modified as tx(data) instead of tx(data, fc), as specified in this example:
In this case, the carrier frequency is set when the system object is set up, so it should not be included in the function call.

More Answers (0)

Categories

Find more on Communications Toolbox in Help Center and File Exchange

Products


Release

R2021a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!