main content

getting started with rf modeling -凯发k8网页登录

learn how to use the rf budget analyzer app to build a simple rf receiver and then create an rf blockset™ circuit envelope multi-carrier model to perform simulation.

build a cascade (row vector) of rf elements.

you can build and analyze an rf cascade by adding elements characterized by their data sheet specifications.

you can use the rf budget analyser app and drag and drop new elements, or you can script the chain elements using matlab® commands. if you are not familiar with the syntax, you can start with app and generate a matlab script.

add elements to your chain in the following order:

  • filter specified by an s-parameters touchstone file

  • low noise amplifier (lna)

  • direct conversion demodulator

  • baseband amplifier

elements(1) = nport('sawfilterpassive.s2p');
elements(2) = amplifier(                                                ...
    'name','lna',                                                       ...
    'gain',18,                                                          ...
    'nf',3,                                                             ...
    'oip3',10);
elements(3) = modulator(                                                ...
    'name','demod',                                                     ...
    'gain',10,                                                          ...
    'nf',6.4,                                                           ...
    'oip3',36,                                                          ...
    'lo',2.45e9,                                                        ...
    'convertertype','down');
elements(4) = amplifier(                                                ...
    'gain',20,                                                          ...
    'nf',11.3,                                                          ...
    'oip3',42);

inspect rf budget using rf budget analyzer app

construct an rfbudget object. the matlab command window dynamically displays the budget analysis results.

b = rfbudget(                                                           ...
    'elements',elements,                                                ...
    'inputfrequency',2.45e9,                                            ...
    'availableinputpower',-70,                                          ...
    'signalbandwidth',8e6)
b = 
  rfbudget with properties:
               elements: [1x4 rf.internal.rfbudget.element]
         inputfrequency: 2.45 ghz
    availableinputpower:  -70 dbm
        signalbandwidth:    8 mhz
                 solver: friis      
             autoupdate: true
   analysis results
        outputfrequency: (ghz) [  2.45    2.45       0       0]
            outputpower: (dbm) [-73.04  -55.04  -45.04  -25.04]
         transducergain: (db)  [-3.044   14.96   24.96   44.96]
                     nf: (db)  [ 2.326   5.699   5.823   5.868]
                   iip2: (dbm) []                              
                   oip2: (dbm) []                              
                   iip3: (dbm) [   inf  -5.674  -5.782  -7.865]
                   oip3: (dbm) [   inf      10   19.89   37.81]
                    snr: (db)  [ 32.62   29.25   29.12   29.08]

or you can visualize the rfbudget object in the app using the matlab command show(b).

generate rf blockset model

use the export button in the rf budget analyzer app to create an rf blockset model or:

exportrfblockset(b)
save_system(gcs,'model_1')

you can use this model for multi-carrier circuit envelope simulation. the / ports and block are set up correctly and you can copy the model for use in any other simulink® testbench.

  • the input port specifies a complex powerwave signal centered at 2.45 ghz.

  • the output ports terminate the cascade and extract the envelope centered at dc (0 hz). the i and q signals are real baseband signals.

  • the configuration block runs the simulation for a total of eight simulation frequencies in order to capture the non linearity introduced by the demodulator and amplifiers.

  • the simulation stop time in this case is set equal to 0. this means that the simulation does only a static analysis of the model (harmonic balance).

observe and understand the model blocks:

  • the s-parameter block describing the filter uses rational fitting in order to simulate frequency data in the time domain. notice that at 2.45 ghz it introduces a phase rotation of approximately -58 degrees.

  • both amplifiers specify ip3, but you can also specify ip2.

  • the demodulator includes ideal channel selection filters. additional impairments can be added such as lo leakage and i/q imbalance.

simulate the model to compare the output power values with the rf budget analyzer app values. notice that due to the phase rotation introduced by the s-parameter block, the complex input signal is partly downconverted on the i and on the q branch, and thus the output power on the two branches is different. for this reason, the gain and other specs of direct conversion receivers are measured at an arbitrary low frequency.

generate measurement testbench

use the export button in the rf budget analyzer app to create a measurement testbench or:

exporttestbench(b)
save_system(gcs,'model_2')

to measure the gain, noise figure, and oip3 use the rf measurement unit dialog box to choose the value you want to verify.

observe and understand the testbench block:

  • you can measure the output on the i or q branches.

  • measurements are done at an arbitrary low frequency

  • measurements are done in the time domain over an arbitrary signal bandwidth

run the following simulation:

  • measure the gain (disable the noise for accurate measurements).

  • measure the nf. reduce the baseband bandwidth to 8e3 for narrowband measurements. in this way, the noise figure measurement is not affected by the filter selectivity.

  • measure the oip3. keep the smaller baseband bandwidth and disable noise for accurate measurements.

on comparing, you will see that the values of gain, noise figure, and ip3 match the values in the rf budget analyzer app reported in the testbench.

see also

rf budget analyzer| | | create custom rf blockset models

网站地图