How to convert signals between built-in and fixed-point data types and illustrates how fixed-point data types affect the representable precision and range. The fixed-point data type used in this model is fixdt(1,5,2), which is a signed 5-bit number with 2 bits to the right of the binary point:
Convert from one fixed-point data type to another fixed-point data type. In this case the conversion is between sfix32_En2 and ufix8_En1, meaning:
Use the FixPt To FixPt Inherited block. Because Simulink® propagates data types throughout a block diagram, fixed-point utility modeling can be templatized for multiple use scenarios. The data type inheritance capability can be given additional information through the use of various relative-type specifications. The FixPt To FixPt Inherited block provides a way to specify that "this signal should have the same fixed-point data type as that signal" by wiring it up to the signals of interest.
您点击了调用以下 MATLAB 命令的链接:
Web 浏览器不支持 MATLAB 命令。请在 MATLAB 命令窗口中直接输入该命令以运行它。
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Contact your local office