寄存器107号:电源管理器1
PWR_MGMT_1:
Description:
This register allows the user to configure the power mode and clock source. It also provides a bit for resetting the entire device, and a bit for disabling the temperature sensor.
该寄存器允许用户配置电源模式和时钟源。它也提供了一位用来重置整个设备,一位用来关闭温度传感器。
By setting SLEEP to 1, the MPU-60X0 can be put into low power sleep mode. When CYCLE is set to 1 while SLEEP is disabled, the MPU-60X0 will be put into Cycle Mode. In Cycle Mode, the device cycles between sleep mode and waking up to take a single sample of data from accelerometer at a rate determined by LP_WAKE_CTRL (register 108). To configure the wake frequency, use LP_WAKE_CTRL within the Power Management 2 register (Register 108).
通过将SLEEP设置为1,MPU60X0可以进入低功耗睡眠模式。当CYCLE被设置为1,而睡眠模式被禁用时,MPU60X0将进入循环模式。在循环模式下,设备在睡眠模式和唤醒模式之间循环,该循环从加速度计获取单个数据样本速率由LP_WAKE_CTRL(108号寄存器)确定。要配置唤醒频率,请使用电源管理器2寄存器的LP_WAKE_CTRL.
An internal 8MHz oscillator, gyroscope based clock, or external sources can be selected as the MPU-60X0 clock source. When the internal 8 MHz oscillator or an external source is chosen as the clock source, the MPU-60X0 can operate in low power modes with the gyroscopes disabled.
可以选择内部8MHz的振荡器,基于陀螺仪的时钟或者外部源可以被选择为MPU60X0的时钟源。当选择8MHz振荡器或外部信号源作为时钟源,MPU60X0可以在陀螺仪禁用的低功耗模式下不工作。
Upon power up, the MPU-60X0 clock source defaults to the internal oscillator. However, it is highly recommended that the device be configured to use one of the gyroscopes (or an external clock source) as the clock reference for improved stability. The clock source can be selected according to the following table.
上电时,MPU60X0时钟源默认为内部振荡器。但是我们更建议将设备时钟设置为其中一个陀螺仪(或者外部时钟源)作为提供稳定性的时钟基准。时钟源可以根据下表选择。
For further information regarding the MPU-60X0 clock source, please refer to the MPU-6000/MPU6050 Product Specification document. Bit 4 is reserved.
有关MPU60X0时钟源的更多消息,请参考MPU6000/MPU6050产品规格文件
Parameters:
DEVICE_RESET When set to 1, this bit resets all internal registers to their default values. The bit automatically clears to 0 once the reset is done. The default values for each register can be found in Section 3.
设置为1时,该位所有内部寄存器复位为默认值。复位完成后,该位自动清零。每个寄存器的默认值可以在第三节中找到。(Register107复位后默认为0x40即0100 0000,所以该位上电复位为0)
SLEEP: When set to 1, this bit puts the MPU-60X0 into sleep mode.
当该位置为1时,该位将MPU60X0置于睡眠模式(上电复位,该位默认为1,所以MPU60X0上电复位默认为睡眠模式,如果需要正常工作,需要先进行唤醒)
CYCLE: When this bit is set to 1 and SLEEP is disabled, the MPU-60X0 will cycle between sleep mode and waking up to take a single sample of data from active sensors at a rate determined by LP_WAKE_CTRL (register 108).
当该位设置为1且SLEEP被禁用时,MPU60X0将在睡眠模式和唤醒模式之间循环。该切换速率从单个数据采样有效传感器的速率由LP_WAKE_CTRL (register 108)确定。
TEMP_DIS: When set to 1, this bit disables the temperature sensor.
设置为1时,该位禁用温度传感器。
CLKSEL[2:0]:3-bit unsigned value. Specifies the clock source of the device
3位无符号值,用于指定设备的时钟源
Register 108 – Power Management 2(108号寄存器,电源管理器2)
PWR_MGMT_2
Description:
This register allows the user to configure the frequency of wake-ups in Accelerometer Only Low Power Mode. This register also allows the user to put individual axes of the accelerometer and gyroscope into standby mode.
The MPU-60X0 can be put into Accelerometer Only Low Power Mode using the following steps:
Set CYCLE bit to 1
Set SLEEP bit to 0
Set TEMP_DIS bit to 1
Set STBY_XG, STBY_YG, STBY_ZG bits to 1
All of the above bits can be found in Power Management 1 register (Register 107).
该寄存器允许用户设置仅加速度计处于低功耗模式下的唤醒频率。该寄存器还允许用户将加速度计和陀螺仪的各个轴置于待机模式。
MPU60X0可以通过以下几个步骤进入仅加速度计低功耗模式:
将CYCLE位设置为1
将SLEEP位设置为0
将TEMP_DIS位设置为1
将STBY_XG,STBY_YG,STBY_ZG位设置为1
所有上述位都可以在电源管理1寄存器(寄存器107)中找到。
In this mode, the device will power off all devices except for the primary I2 C interface, waking only the accelerometer at fixed intervals to take a single measurement. The frequency of wake-ups can be configured with LP_WAKE_CTRL as shown below.
在此模式下,器件将关闭除主IIC之外的所有器件接口,仅唤醒加速度计以固定的时间间隔进行单次测量。唤醒的频率可以如下所示配置LP_WAKE_CTRL。
For further information regarding the MPU-6050’s power modes, please refer to Register 107.
有关MPU6050电源模式的更多信息,请参阅寄存器107
The user can put individual accelerometer and gyroscopes axes into standby mode by using this register. If the device is using a gyroscope axis as the clock source and this axis is put into standby mode, the clock source will automatically be changed to the internal 8MHz oscillator.
用户可以通过使用寄存器将各个加速度计和陀螺仪的轴置于待机模式。如果设备使用陀螺仪轴作为时钟源并且这个轴处于待机模式,时钟源将自动更改为内部的8MHz振荡器。
Paeameters:
LP_WAKE_CTRL: 2-bit unsigned value. Specifies the frequency of wake-ups during Accelerometer Only Low Power Mode.
2位无符号值,指定仅加速度计在低功耗期间的唤醒频率。
STBY_XA: When set to 1, this bit puts the X axis accelerometer into standby mode.
设置为1时,该位将X轴加速度计置于待机模式
STBY_YA: When set to 1, this bit puts the Y axis accelerometer into standby mode.
设置为1时,该位将Y轴加速度计置于待机模式
STBY_ZA: When set to 1, this bit puts the Z axis accelerometer into standby mode.
设置为1时,该位将Z轴加速度计置于待机模式
STBY_XG: When set to 1, this bit puts the X axis gyroscope into standby mode.
设置为1时,该位将X轴陀螺仪置于待机模式
STBY_YG: When set to 1, this bit puts the Y axis gyroscope into standby mode.
设置为1时,该位将Y轴陀螺仪置于待机模式
STBY_ZG: When set to 1, this bit puts the Z axis gyroscope into standby mode.
设置为1时,该位将Z轴陀螺仪置于待机模式