SBAS934A June 2020 – December 2021 TMAG5170-Q1
PRODUCTION DATA
The TMAG5170-Q1 calculates the angle based off the ANGLE_EN register bit settings. Figure 7-8 shows that the ANGLE_RESULT register stores the angle information in the 13-LSB bits. Bits D04-D12 store angle integer value from 0 to 360 degree. Bits D00-D03 store fractional angle value with a resolution of 1/16 degree. The 3-MSB bits are always populated as b000. The TMAG5170-Q1 CORDIC offers angle resolution of 1/4 degree. An external CORDIC may be used if higher angle resolution is required. Use Equation 7 to calculate the angle.
where
For example: a 354.50 degree is populated as 0001 0110 0010 1000b and a 17.25 degree is populated as 0000 0001 0001 0100b.
With DATA_TYPE ≠ 00b, the D01-D12 bits from the ANGLE_RESULT register can be accessed. In this mode, the angle fractional value is represented by 3 bit with resolution of 1/8 degree. Use Equation 8 to calculate the angle in degree.
During the angle calculation, use Equation 9 to calculate the resultant vector magnitude.
where
Figure 7-9 shows the magnitude value stored in the MAGNITUDE_RESULT register. This value should be constant during 360 degree angle measurements.
The magnitude result can be accessed through SPI in 16-bit or 12-bit formats. In the 12-bit format, bit D01 to bit D12 are sent through the SPI.