Fixed-Point Designer 快速入门
定点和浮点算法的建模和优化
Fixed-Point Designer™ 提供用于在嵌入式硬件上优化和实现定点和浮点算法的数据类型和工具。其中包括定点和浮点数据类型以及特定于目标的数值设置。使用 Fixed-Point Designer,您可以执行定点位真的目标感知仿真。然后,在硬件上实现设计之前,您可以测试和调试量化效应,如溢出和精度损失。
Fixed-Point Designer 提供 App 和工具,用于分析双精度算法并将它们转换为精度降低的浮点或定点。优化工具使您能够选择满足数值精度要求和目标硬件约束的数据类型。为了高效实现,您可以用硬件最优模式(如压缩查找表)来代替计算成本高昂的设计构造。
C 和 HDL 生产代码可以直接从您的定点和浮点优化模型中生成。
教程
- 在 MATLAB 中创建定点数据
定点基础知识。 - 定点算术运算
执行定点算术运算。 - 查看定点数据
代码示例中使用的fi
对象显示设置。 - 加速定点仿真
此示例说明如何使用fiaccel
函数来加速定点算法。您可以从 MATLAB® 代码生成 MEX 函数,运行生成的 MEX 函数,并使用 MATLAB 代码仿真比较执行速度。 - Set Data Types Using Min/Max Instrumentation
This example shows how to set fixed-point data types by instrumenting MATLAB® code for min/max logging and using the tools to propose data types. - 生成定点 C 代码
生成独立的定点 C 代码。 - 手动将浮点 MATLAB 算法转换为定点
将浮点型 MATLAB 算法手动转换为定点类型。 - Developing and Testing Fixed-Point Systems
Overview of the development cycle for simulating dynamic systems. - Pass Fixed-Point Data Between Simulink Models and MATLAB
Reading fixed-point data from MATLAB into your Simulink® models, and logging fixed-point information from your models and simulations to the workspace. - Configure Blocks with Fixed-Point Output
Fixed-point model creation by configuring Simulink blocks to output fixed-point signals. - Cast from Doubles to Fixed Point
Example based on thefxpdemo_dbl2fix
model, which highlights many of the key features of the Fixed-Point Designer software. - Convert Floating-Point Model to Fixed Point
Use the Fixed-Point Tool to convert a floating-point model to fixed point. - Sharing Fixed-Point Models
Data type override settings for sharing and editing a model containing fixed-point blocks without the Fixed-Point Designer software.
MATLAB 工作流
Simulink 工作流
关于定点
- 定点硬件的好处
定点硬件在大小和功耗、内存使用量、速度和成本方面具有优势。
- 定点数据类型
定点数据类型表示。
- 精度和范围
讨论 Fixed-Point Designer 中算术运算背后的概念。
- 定标
讨论 Fixed-Point Designer 中使用的定标类型;二进制小数点定标和 [Slope Bias] 定标。
- 算术运算
介绍 Fixed-Point Designer 中算术运算的相关概念。
- Physical Quantities and Measurement Scales
Overview of measurement scales and representing numbers.
- 精选参考书目