And what is the best way to build a model from the beginning in a smaller data type like uint16 wihout using many Cast blocks and Converters?
I would like to convert data of double type to single type before code generation in 2020A Simulink, without using Cast blocks on most functions.
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Scott McNeil
am 3 Mär. 2023
Kommentiert: Scott McNeil
am 8 Mär. 2023
I would like to do this without using Cast blocks on most functions.
Akzeptierte Antwort
Fangjun Jiang
am 7 Mär. 2023
See this example
3 Kommentare
Fangjun Jiang
am 7 Mär. 2023
The code generated after running set_param(gcs, 'DataTypeOverride', 'Single') shows using real32_T, which is float (single).
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Simulink Coder finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!