fxptdlg

Launch the Fixed-Point Blockset Interface tool.

Syntax

fxptdlg('model')

Description

fxptdlg('model') launches the Fixed-Point Blockset Interface tool for the fixed-point MDL-file model. The interface provides convenient access to the global overrides and min/max logging settings, the logged min/max data, the automatic scaling script, and the plot interface tool. You can launch the Interface tool for as many different MDL-files as you want, and the tool controls only the specified model. You can also invoke the Interface tool from the Tools menu in the model window, or with the Fixed-Point GUI block, which is included with all blockset demos.

For each block in the model that logs data, the Interface tool displays the block names, the minimum simulation value, the maximum simulation value, the data type, and the scaling. Additionally, if a signal saturates or overflows, then a message is displayed for the associated block indicating how many times saturation or overflow occurred. You can display a block's dialog box by double-clicking on the appropriate entry.

Parameters and Dialog Box

  • The Log Min/Max - This menu controls which blocks log data. All logs min/max data for all blocks, None doesn't log any min/max data, and Use block params logs min/max data for all blocks that have the Log minimums and maximums check box checked.

  • Log Mode - This menu controls how the log file is updated when multiple simulations are run. Override log updates all logged values for each simulation run. Merge log keeps the highest and lowest logged values across multiple simulations.

  • Autoscale % Safety Margin - This parameter multiplies the simulation values by the specified factor, and allows you to specify a range differing from that defined by the maximum and minimum values logged to the workspace. For example, a value of 55 specifies that a range at least 55 percent larger is desired. A value of -15 specifies that a range up to 15 percent smaller is acceptable. The Autoscale % Safety Margin parameter is used as part of the automatic scaling procedure. Before automatic scaling is performed, you must run the simulation to collect min/max data.

  • Doubles Override - This menu controls whether the output data type is overridden with doubles. All overrides the output data type for all blocks, None doesn't override the output data type for any block, and Use block params overrides the output data type for blocks that have the Override data type(s) with doubles check box checked.

  • Block path - Displays the path for each selected block. The block path is described in terms of the blockset model name and, if required, the subsystem names.

The Fixed-Point Blockset Interface tool contains six buttons. The Run button runs the model and updates the display with the latest simulation information. The Stop button stops the simulation from running. The Autoscale button invokes the automatic scaling script autofixexp. The Plot button invokes the Plot System interface, which displays any To Workspace, Outport, or Scope blocks in the model. The Help button displays the HTML-based help. The Close button closes the Interface tool.

The Plot System interface is shown below. It is displaying Scope block output from the fxpdemo_feedback demo.

To plot the simulation results, select one or more variable names, and then select the appropriate plot button. You plot the raw signal data with the Plot Signals button. Raw signal data is generated when the global override switch is off. You plot doubles with the Plot Doubles button. Doubles are generated when the global override switch is on. You can plot both raw signal data and doubles with the Plot Both button. Note that the doubles override does not overwrite the raw data.