Export Spectrum Analyser trace to workspace or file
Afficher commentaires plus anciens
Hi, as the title says, I want to find out how to export the trace (dBm) from a Spectrum Analyser, in Simulink, to either the workspace or preferably to an external (EXCEL spreadsheet) file ?
1 commentaire
Derek Eccles
le 17 Mar 2020
Réponses (1)
Fangjun Jiang
le 17 Mar 2020
Modifié(e) : Fangjun Jiang
le 17 Mar 2020
0 votes
Run this to open the document and example, I believe the answer can be found there. The key is probabaly the function getMeasurementsData()
web(fullfile(docroot, 'dsp/ref/dsp.spectrumanalyzer.getmeasurementsdata.html'))
or from https://www.mathworks.com/help/releases/R2019b/dsp/ref/dsp.spectrumanalyzer.getmeasurementsdata.html
8 commentaires
Derek Eccles
le 17 Mar 2020
Derek Eccles
le 17 Mar 2020
Fangjun Jiang
le 17 Mar 2020
What are you trying to do with this? "sablock" is goint to have the same value as "fsk"
sablock = fsk, '/Spectrum Analyzer'
Open the html weblink, there is a model, there is a spectrum analyzer block, there are example code!
Derek Eccles
le 18 Mar 2020
Fangjun Jiang
le 18 Mar 2020
Then, it should be sablock='fsk/Spectrum Analyzer'. Or, click (once) the Spectrum Analyzer block in your model, go to Command Window, type "sablock=gcb" and you'll get the full path of the Spectrum Analyzer block. Then follow the example in the webpage.
I don't know why your previous post shows some numerical numbers.
Derek Eccles
le 18 Mar 2020
Fangjun Jiang
le 19 Mar 2020
Modifié(e) : Fangjun Jiang
le 19 Mar 2020
They all depend on your simulation data and setting.
If your model name is 'fsk.slx', then specifying the full path of the scope block should be scope='fsk/Spectrum Analyzer'. type "fsk" before and after the simulation to see what happened. "fsk" should just bring up your model.
Derek Eccles
le 19 Mar 2020
Catégories
En savoir plus sur FSK dans Centre d'aide et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!