1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
//! Motion detection configuration for the MPU-6050.
//!
//! The MPU-6050 provides hardware motion detection capabilities that can efficiently
//! detect movement without constant CPU monitoring. The detection works by:
//!
//! 1. Comparing consecutive accelerometer samples
//! 2. Triggering when the difference exceeds the configured threshold
//! 3. Only signaling after the threshold is exceeded for the specified duration
//!
//! Key concepts:
//! - Threshold (in mg): How much acceleration change triggers detection
//! - Duration (in samples): How many consecutive samples must exceed threshold
//! - High-pass filter: Removes gravity bias for better motion isolation
//! - All-axis detection: Monitors movement in any direction
//!
//! For best results:
//! - Use lower threshold (2-10mg) for subtle movement detection
//! - Use shorter duration (1-5ms) for quick response
//! - Enable the high-pass filter to remove gravity effects
//! - Configure all axes for complete motion coverage
/// Motion detection configuration parameters
/// Indicates if motion was detected based on the configured threshold and duration
;