Main Content

Executable Specification for System Design

This example shows how to use the Model-Based Design methodology to overcome the challenge of exchanging specifications, design information, and verification models between multiple design teams working on a single project. The example uses a simple project: an executable specification that encapsulates information from all teams. The example includes information on how to use Signal Processing Toolbox™, DSP System Toolbox™, Communications Toolbox™, RF Toolbox™, and RF Blockset™ in a multi-domain design.

Figure 1: Bridging the Jargon Gap between RF and System Engineers

Model-Based Design

Model-Based Design uses a system-level model at the center of the development process. Before partitioning the system-level model among various design teams, the initial system model, developed by the system engineer, is validated against requirements and standards. With a validated error-free executable specification, design and implementation go smoothly. As the design progresses, verification can include co-simulation and testing with hardware-in-the-loop.

Figure 2: Model-Based Design -- A system-level model is at the center of the development process

Rather than talking about all the elements in the development flow, this example focuses on how Model-Based Design aids your engineering teams. The idea is to enable the System Engineer to initially create an executable specification in the form of a Simulink model that can be distributed to design teams. A team, such as the RF team, will devise a subsystem, extract a verification model and import it into the RF Toolbox. The RF team then returns the solution to the System Engineer, who reevaluates the overall performance of the system with the impairments from the RF subsystem. The design teams can go back and forth, iterating to find an optimal solution as the design proceeds. Perhaps the RF section can use a more efficient or less costly device if the signal processing algorithms are altered. Or, perhaps a small increase in fixed-point wordlength can free up some of the implementation loss budgeted, and enable a lower cost RF component to be used. The opportunities for cross-domain optimization are enhanced by this Model-Based design methodology.

Baseline Model: Communications Toolbox™ with No RF Modeling

open('rfb_receiver_0.slx')

The model rfb_receiver_0.slx shows the kind of Communication System Toolbox model that inspired the creation of the RF Blockset Equivalent Baseband library. Note that this is a simple model for illustrative purposes. Communications Toolbox includes more complex models of WCDMA, 802.11, DVB-S2, etc. However, the concepts presented can be applied to more complex models as well.

The simple wireless communication system consists of a message source, QAM modulator, root raised cosine filter and an AWGN channel. The model is an executable specification, and is used to validate the specification against requirements and acceptance criteria, "At a BER of 1e-3, the Eb/No must be no greater than 1dB above the theoretical bound for 16QAM."

To validate the spec, you can use a previously saved BERTool session file rfb_receiver_0.ber. To find this file, type the following command at the MATLAB prompt

which rfb_receiver_0.ber

Open the BERTool using the MATLAB command bertool. From the File==>Open Session... dialog box, navigate to the saved session rfb_receiver_0.ber. Now click on the Monte Carlo tab, and then click on the Run button. A figure like the one below is generated:

Figure 3: BER versus Eb/No plot without RF impairments

The Eb/No for a given BER value is a little higher than the theoretical bound because of implementation losses. (In the present case, the main loss is due to the finite length of the root raised cosine filters.) But the degradation is within acceptance criteria.

Adding RF Specifications to the Baseline Model

open('rfb_receiver_1.slx')

Let's elaborate the baseline model and see how it changes with additional refinement using RF Blockset components. The first step is to replace the AWGN block with a path loss block (shown in the preceding figure in cyan); this will lower the signal level close to the end of range value. The path loss (in dB) required to bring the unit power (1W) down to a given Eb/No (also in dB) at the receiver input is:

path_loss = 10*log10(k*T_ref*B*M) + EbNo + NF

where k is Boltzmann's constant (~1.38e-23 J/K), T_ref is the IEEE® standard noise reference temperature (290K), B is the noise bandwidth (~50 MHz in this case), and NF is the receiver noise figure in dB.

Next, the cyan-colored RF receiver subsystem and AGC Blocks are included. The AGC Block is a consequence of using realistic signal levels required by the demodulator.

The RF Receiver Subsystem Examined

open('rfb_receiver_1.slx')
open_system('rfb_receiver_1/RF Receiver')

Now examine the RF Receiver subsystem, which is a cascaded model of a super heterodyne receiver. The receiver uses blocks from the RF Blockset Equivalent Baseband library. The Simulink signal enters the RF domain through a gateway "Input Port" block. Notice that the connectors after the gateway are different. The standard Simulink arrows have been replaced with RF connection lines. This is to remind us that RF signals are bidirectional. The receiver is a cascade of components each represented as a 2-port network: a filter, a LNA, a mixer, and an IF strip. The Output Port, in this case, is not only the gateway back to Simulink but also represents an ideal quadrature down conversion mixer. Here is a framework or architecture for a receiver that is not yet designed. An executable specification for the RF engineer has been created. Each stage of the RF subsystem includes a budget for the overall gain, noise and nonlinearities, as shown in the following figure.

Figure 4: Specification of Amplifier Block Parameters

As an example of budgeting, consider the front end filter in the above figure. The S-parameters are specified at a single frequency point using the first element of the gainVec array that was entered into the base workspace using the PostLoadFcn* under the Callbacks tab in the Model Properties panel. Each element of the array refers to a stage, so the index 1 refers to the first stage. Values for OIP3, on the Nonlinearity data tab, and for Noise Figure, on the Noise data tab, are similarly specified.

Figure 5: Specification of Complex Baseband-Equivalent Simulation Parameters

Now open the Input Port block. This port contains parameters that apply to the overall RF subsystem. A narrowband modeling approach is used to capture the in-band effects that impact downstream signal processing blocks. The range of frequencies is specified through the Center frequency parameter, the Sample time parameter (which is 1/Bandwidth), and the Finite impulse response filter length parameter (which is the length of the impulse response filters that are used in modeling RF components). A longer length time-domain filter will give finer frequency-domain resolution within the specified bandwidth. To model mismatch at the input of the first component, source impedance is also specified here. Notice the "Add noise" checkbox. To include noise in the simulation, you must select this "Add noise" checkbox.

Figure 6: Noise Modeling with the RF Blockset Equivalent Baseband library

The AWGN block models overall noise as a signal-to-noise ratio. By contrast, blocks from the RF Blockset Equivalent Baseband library model noise by adding the noise contribution of each block individually. For each block, the noise is modeled using an appropriate formulation determined by the set of noise parameters supplied for that block. Once the noise for each block is calculated, the overall system noise model is developed. This overall model includes the position of each block in the cascade (i.e., includes the gain of the subsequent stages).

Figure 7: BER versus Eb/No plot with RF impairments

Plots of BER versus Eb/No comparing the theoretical, Baseline and Baseline with RF impairments models are given in Figure 7. This is a simple illustration of the convenience afforded by the Model-Based Design methodology. At this point in the process, an executable specification has been developed. This specification will be used by teams to design their subsystems. In the case of the RF subsystem, the abstract RF blocks will be replaced by discrete components. As each RF block is realized, its effect on the system's design criteria can be assessed.

bdclose('rfb_receiver_0');
bdclose('rfb_receiver_1');

See Also

S-Parameters Amplifier

Related Topics

Effect of Nonlinear Amplifier on 16-QAM Modulation