Freescale Semiconductor FRDM-FXS-MULTI 데이터 시트

다운로드
페이지 100
FXOS8700CQ
Sensors
62
Freescale Semiconductor, Inc.
10.10
Accelerometer vector-magnitude function
The accelerometer vector-magnitude function is an inertial event detection function available to assist host software algorithms 
in detecting motion events.
If 
 > A_VECM_THS for a time period greater than the 
value stored in A_VECM_CNT, the vector-magnitude change event flag is triggered.
a_x_out, a_y_out, and a_z_out are the current accelerometer output values, and a_x_ref, a_y_ref, and a_z_ref are the reference 
values stored internally in the ASIC for each axis or in A_VECM_INIT_X/Y/Z registers if A_VECM_CFG[a_vecm_initm] is set.
Please note that the x_ref, y_ref, and z_ref values are not directly visible to the host application through the register interface. 
Please refer to Freescale application note 4458.
10.10.1 A_VECM_CFG (0x5F) register
Table 93. A_VECM_CFG register
a_vecm_ele
a_vecm_initm
a_vecm_updm
a_vecm_en
0
0
0
 
0
 
0
0
0
0
Table 94. A_VECM_CFG bit descriptions
Field
Description
a_vecm_ele
Control bit a_vecm_ele defines the event latch enable mode. Event latching is disabled for a_vecm_ele = 0. In this 
case, the vector-magnitude interrupt flag is in updated real-time and is cleared when the condition for triggering the 
interrupt is no longer true. The setting and clearing of the event flag is controlled by the A_VECM_CNT register’s 
programmed debounce time.
For a_vecm_ele = 1, the interrupt flag is latched in and held until the host application reads the INT_SOURCE register 
(0x0C).
a_vecm_initm
Control bit a_vecm_initm defines how the initial reference values (x_ref, y_ref, and z_ref) are chosen. 
For a_vecm_initm = 0 the function uses the current x/y/z accelerometer output data at the time when the vector
magnitude function is enabled. 
For a_vecm_initm = 1 the function uses the data from A_VECM_INIT_X/Y/Z registers as the initial reference values.
 a_vecm_updm
Control bit a_vecm_updm defines how the reference values are updated once the vector-magnitude function has been 
triggered. 
For a_vecm_updm = 0, the function updates the reference value with the current x, y, and z accelerometer output data 
values. 
For a_vecm_updm = 1, the function does not update the reference values when the interrupt is triggered. Instead the 
function continues to use the reference values that were loaded when the function was enabled. If both a_vecm_initm 
and a_vecm_updm are set to logic ‘1’, the host software can manually update the reference values in real time by 
writing to the A_VECM_INITX,Y,Z registers.
a_vecm_en
The accelerometer vector-magnitude function is enabled by setting a_vecm_en = 1, and disabled by clearing this bit 
(default). The reference values are loaded with either the current X/Y/Z acceleration values or the values stored in the 
A_VECM_INIT_X/Y/Z registers, depending on the state of the a_vecm_initm bit.
Note: The vector-magnitude function will only perform correctly up to a maximum ODR of 400 Hz.
a_x_out
a_x_ref
(
)
2
a_y_out
a_y_ref
(
)
2
a_z_out
a_z_ref
(
)
2
+
+