How can I avoid doubles from char arithmetic in fixed-point codegen in MATLAB Coder R2025a?
이전 댓글 표시
I am generating fixed-point code using Fixed-Point Designer and MATLAB Coder R2025a. My code will be used on a small embedded microcontroller that does not support floating-point operations. One of the lines of code that is being translated as resulting in data of type
"double" rather than "char" is the following:
x(:) = (s(i) - '0');
where "s" is a character array.
What do I need to do to get the generated code to not use doubles in instances like this?
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Create Fixed-Point Objects in MATLAB에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!