Main Content

getDesignRangeSpecification

Class: coder.FixPtConfig
Namespace: coder

Get design range specifications for parameter

Syntax

[designMin, designMax] = getDesignRangeSpecification(fcnName,paramName)

Description

[designMin, designMax] = getDesignRangeSpecification(fcnName,paramName) gets the minimum and maximum values specified for the parameter, paramName, in function, fcnName.

Input Arguments

expand all

Function name, specified as a string.

Data Types: char

Parameter name, specified as a string.

Data Types: char

Output Arguments

expand all

Minimum value allowed for this parameter, specified as a scalar double.

Data Types: double

Maximum value allowed for this parameter, specified as a scalar double.

Data Types: double

Examples

Get Design Range Specifications

% Set up the fixed-point configuration object
cfg = coder.config('fixpt');
cfg.TestBenchName = 'dti_test';
cfg.addDesignRangeSpecification('dti', 'u_in', -1.0, 1.0)
cfg.ComputeDerivedRanges = true; 
% Get the  design range for the 'dti' function parameter 'u_in' 
[designMin, designMax] = cfg.getDesignRangeSpecification('dti','u_in')
designMin =

    -1


designMax =

     1