Why answer of uint8 in .m and mdl are different?
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
nkumar
am 27 Jul. 2015
Beantwortet: Walter Roberson
am 27 Jul. 2015
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 Kommentare
Akzeptierte Antwort
Walter Roberson
am 27 Jul. 2015
Notice that Saturate on Integer Overflow defaults to Off; you want it to be On.
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Sources 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!