フィルターのクリア

Simulink Fixed point to Floating Conversion

2 ビュー (過去 30 日間)
Mashrur Alam
Mashrur Alam 2021 年 6 月 9 日
コメント済み: Mashrur Alam 2021 年 6 月 9 日
I am using fixed point designer to convert a single floating type value to a 32bit fixed point value. How to I convert the fixed point type back to floating type. I tried the below but that only gives the integer component of the floating point number. I also want to get back the fractional component. I tried changing the convert block's output type to be RWV instaed of the SI to no success.

採用された回答

Andy Bartlett
Andy Bartlett 2021 年 6 月 9 日
編集済み: Andy Bartlett 2021 年 6 月 9 日
Notice the "(SI)" shown on the icons of the data type conversion blocks.
That means the block is using the less common "Stored Integer Value Mode", instead of the default "Real World Value Mode".
(SI) mode ignores scaling and is not what you want in your use case.
If you reconfigure the data type conversion blocks to use
Input and output to have equal: Real World Value (RWV)
then you'll get the behavior you are seeking.
  1 件のコメント
Mashrur Alam
Mashrur Alam 2021 年 6 月 9 日
Thanks! This worked.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeFixed-Point Designer についてさらに検索

製品


リリース

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by