HDL Coder (2014b) fixed point division RoundMode error

조회 수: 1 (최근 30일)
Chris Stathis
Chris Stathis 2014년 12월 1일
답변: Kiran Kintali 2021년 5월 24일
I am passing a Matlab script to the HDL Coder. In the Workflow Advisor, during Fixed-Point Conversion, I specify the fimath RoundingMethod as Zero. I have confirmed that the generated _fixpt script contains calls to fimath with this RoundingMethod.
At the HDL Code Generation step, I get the following error in the Workflow Advisor:
hdlcoder:matlabhdlcoder:bad_ir The MATLAB design contains constructs that are unsupported for HDL code generation.
And in the Conformance Report, I see the following error:
Found unsupported division expression for HDL code generation; Signed input data type is not supported for division with Floor RoundMode.
There are no other errors in the Conformance Report. Under "Function Calls Requiring Attention", I see my script name and "divide, fi".
Why am I getting errors about using Floor RoundMode when I am not configuring fimath to use Floor??
I am running Matlab 2014b on Linux. Version information below:
MATLAB Version 8.4 (R2014b)
Simulink Version 8.4 (R2014b)
Communications System Toolbox Version 5.7 (R2014b)
Control System Toolbox Version 9.8 (R2014b)
Curve Fitting Toolbox Version 3.5 (R2014b)
DSP System Toolbox Version 8.7 (R2014b)
Embedded Coder Version 6.7 (R2014b)
Fixed-Point Designer Version 4.3 (R2014b)
Fuzzy Logic Toolbox Version 2.2.20 (R2014b)
HDL Coder Version 3.5 (R2014b)
HDL Verifier Version 4.5 (R2014b)
Image Processing Toolbox Version 9.1 (R2014b)
MATLAB Coder Version 2.7 (R2014b)
MATLAB Compiler Version 5.2 (R2014b)
MATLAB Report Generator Version 4.0 (R2014b)
Model Predictive Control Toolbox Version 5.0 (R2014b)
Neural Network Toolbox Version 8.2.1 (R2014b)
Optimization Toolbox Version 7.1 (R2014b)
Partial Differential Equation Toolbox Version 1.5 (R2014b)
Robust Control Toolbox Version 5.2 (R2014b)
Signal Processing Toolbox Version 6.22 (R2014b)
SimPowerSystems Version 6.2 (R2014b)
Simscape Version 3.12 (R2014b)
Simulink Coder Version 8.7 (R2014b)
Simulink Control Design Version 4.1 (R2014b)
Simulink Design Optimization Version 2.6 (R2014b)
Simulink Report Generator Version 4.0 (R2014b)
Simulink Verification and Validation Version 3.8 (R2014b)
Stateflow Version 8.4 (R2014b)
Symbolic Math Toolbox Version 6.1 (R2014b)
System Identification Toolbox Version 9.1 (R2014b)
Wavelet Toolbox Version 4.14 (R2014b)

답변 (1개)

Kiran Kintali
Kiran Kintali 2021년 5월 24일
Consider using hdlfimath when generating HDL code from MATLAB with fixed-point.
>> hdlfimath

카테고리

Help CenterFile Exchange에서 FPGA, ASIC, and SoC Development에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by