Changes to OQPSK Modulator objects after r2017
2 次查看(过去 30 天)
显示 更早的评论
I'm working with some old code that created an OQPSK signal with RRC pulse shaping and I'm trying to recreate some of its outputs. The signals originally produced by the code were using Matlab 2017a, and I'm currently using 2019a. The function signature for the OQPSKModulator object has changed between the two versions, but attempting to keep all things as equal as possible, the two versions create different constellations. The 2017 version also produces data twice as long as the 2019 version. What is the difference that is causing this?
Here is the 2017 code:
% 2017 Code
sps = 8;
hOQPSK = comm.OQPSKModulator('BitInput',true,'OutputDataType','single');
hTXFILT = comm.RaisedCosineTransmitFilter('FilterSpanInSymbols',10,'RolloffFactor',0.5,...
'OutputSamplesPerSymbol',sps,'Gain',sqrt(sps));
bits = randi([0,1], 1000, 1);
oqpsk = hOQPSK(bits);
oqpsk = hTXFILT(oqpsk)
and the 2019 code:
% 2019 Code
sps = 8;
hOQPSK = comm.OQPSKModulator('BitInput', 1, 'PulseShape','Root raised cosine','RolloffFactor',0.5,...
'FilterSpanInSymbols',10,'SamplesPerSymbol',sps);
bits = randi([0,1], 1000, 1);
oqpsk = hOQPSK(bits);
0 个评论
采纳的回答
Siriniharika Katukam
2020-2-21
Hi
One thing you have missed is to set the output datatype in 2019 code. The default is ‘double’ in 2019 but it is defined as single in 2017 code. The following link might be helpful:
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Modulation 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!