Arduino due vs Uno

When I run the same sketch on Uno and on due I haven’t the same results.
I think it is due to the bits format (8 vs 32). Is there any solution to adapt uno sketches to arduino Due.

example program ?



sensor immovable (same position for all tests)
UNO and DUE, every one repeat same values.
but values are different between UNO and DUE.

for example UNO gives:
ypr -34.54 -4.58 -0.11
but DUE gives :
ypr 2.78 -4.59 -0.24

Any help please. thanks

my best tip

Test with MPUteapot processing. ( Plz see the pic.)
Any idea about what is causing difference between Uno ans Due?

Due vs Uno.bmp (1.14 MB)