Hi J,03 contains X low byte, 04 X high byte etc.
If you make correctly a function periph_rd()
you can do
X.lb = periph_rd ( 0x83 )
X.hb =periph_rd ( 0x84 )
Y.lb = periph_rd ( 0x85 }
etc...
Testing data ready might be needed.
2's complement conversion, when calculating the angles.
So that I could see all of the relevant CODE at the same time, I removed the FUNCTION, also at the moment I'm not using the calc function.
I'll try X.LB = 0x83 etc next.
I can try testing DRDY_PIN, but it may not be necessary, as it happens as SINGLE READ is WRITEn, after which the DATA is always there, and stays till ST2 is READ. (I think I'm correct)
I can always use DRDY_PIN later if necessary.
Thanks.
C
Last edited: