Why answer of uint8 in .m and mdl are different?
조회 수: 1 (최근 30일)
이전 댓글 표시
I have a value of -1.In .m file if i process uint8(-1) i get answer as 0,but in simulink if i feed a constant with -1 and use data conversion of uint8 i get answer as 255.Why do i get different answers.
댓글 수: 0
채택된 답변
Walter Roberson
2015년 7월 27일
Notice that Saturate on Integer Overflow defaults to Off; you want it to be On.
댓글 수: 0
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Sources에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!