# MATE Power Manager Manual

是 MATE Desktop 的会话守护进程，用于管理笔记本电脑或台式机的电源设置。

2015-2021
MATE 文档团队
2006-2009
Richard Hughes (richard@hughsie.com)
MATE 文档团队
Richard Hughes

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License (GFDL), Version 1.1 or any later version published by the Free Software Foundation with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. You can find a copy of the GFDL at this link or in the file COPYING-DOCS distributed with this manual.

本手册是在 GFDL 许可之下分发的 MATE 手册集合的一部分。如果想要单独分发此手册，可以在手册中添加该许可证的一份副本然后分发，如该许可证的第 6 部分所述。

各个公司使用的许多用于区别它们产品和服务的名称都声明为商标。在所有的 MATE 文档以及 MATE 文档项目的成员中，这些名称都是以全大写字母或首字母大写显示，从而表明它们是商标。

本文档和文档是根据 GNU 免费文档许可协议的条款提供的，并且还有进一步的阐述:

1. 文档按“原样”提供，不提供任何明示或暗示的保证，包括但不限于：文档或文档的修改版本没有适销性方面的缺陷、适合特定目的的适用性，以及没有侵权行为。您将自行承担本文档以及文档修改版本的质量、准确性以及性能方面的风险。如果任何文档或文档修改版本存在缺陷，您(而不是最初的编写者、作者或撰写人)将承担所有必需的服务、维修或更正的费用。此免责声明是本许可证的重要组成部分。如果不接受此免责声明，那么您就没有权利使用任何文档或文档的修改版本；并且

2. 无论在任何情况以及在任何法律理论下，本文档或文档修改版本的作者、最初的编写者、任何撰写人或任何分发者，或者任意这些方的任何提供者都不对任何人由于使用本文档或文档修改版本引起或带来的任何直接的、间接的、特殊的、偶然的或继发的损失承担任何民事(包括疏忽)、合同或其它方面的责任，这些损失包括但不限于信誉损失、工作停止、计算机失败或故障，或任何以及所有其它损失或由此引发的或与之相关的损失，即使这些方已被告知存在出现此类损失的可能性时也是如此。

## Software Licence

MATE Power Manager is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

MATE Power Manager is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with MATE Power Manager; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.

MATE Documentation Team
Richard
Hughes
richard@hughsie.com
2.0
2006-08-30

Richard Hughes richard@hughsie.com

Richard Hughes

## 反馈

To report a bug or make a suggestion regarding the MATE Power Manager application or this manual, follow the directions in the MATE Power Manager Contact Page.

Christopher Meng
i@cicku.me
2012-2013
Christopher Meng
ravix
dr.neemous@gmail.com
2013
ravix
Dianjin Wang
1132321739qq@gmail.com
2012
Dianjin Wang
Cravix
dr.neemous@gmail.com
2013
Cravix
nyanyh
rebuilty@gmail.com
2013
nyanyh
liulitchi
xingzuo88@qq.com
2013
liulitchi
玉堂白鹤
yjwork@qq.com
2015
玉堂白鹤
Mingye Wang
arthur200126@gmail.com
2015-2016
Mingye Wang
白铭骢
jeffbai@aosc.xyz
2015-2016
白铭骢
刘子兴
liushuyu@aosc.xyz
2015-2016
刘子兴

## 介绍

MATE 电源管理器 会话守护进程是一个电源管理守护进程，用于MATE desktop

## 用法

MATE Power Manager is usually started in MATE startup, but you can manually start MATE Power Manager by doing:

命令行

  Type `G_MESSAGES_DEBUG=PowerManager mate-power-manager --no-daemon`, then press Return:

## Notification Messages

When MATE Power Manager has started, the following notifications may be displayed.

### AC Adapter Unplugged

#### MATE Power Manager Notification when AC adapter is removed

You can disable this notification by changing the dconf key `org.mate.power-manager notify-discharging`.

### Fully Charged

#### MATE Power Manager Notification when laptop primary battery is fully charged

You can disable this notification by changing the dconf key `org.mate.power-manager notify-fully-charged`.

You will only get a repeat notification if your battery percentage charge drops below 95% and then is again fully charged. This prevents some machines from showing unwanted repeat notifications if the battery is incorrectly reporting the charged status.

### 低能耗

当电池电量不足时，您将收到以下通知。 您应该尽快切换到交流电源。

#### MATE Power Manager Notification when battery power is low

You can disable this notification by changing the dconf key `org.mate.power-manager notify-low-power`.

### 电量严重不足

当计算机电量耗尽时，将显示此通知，说明需要采取什么措施。 您可以使用首选项工具更改电量严重不足时的操作。

#### MATE Power Manager Notification when the system power is critically low

### 挂起失败

When a Suspend Failure occurs you may get this following warning. The most common reason for this notification is that the current user does not have permission to suspend or hibernate the computer.

#### MATE Power Manager Notification when suspend failure occurs

You can disable this notification by changing the dconf key `org.mate.power-manager notify-sleep-failed`.

## 统计

The statistics program allows you to visualize the power consumption of your laptop hardware.

This has been removed from the information window of previous versions of MATE Power Manager as the data interface is now using DBUS rather than internal IPC. This allows other applications to query and display the data if required.

### Power History going from battery power to AC

You may not see some options or graphs if your computer does not have the required hardware. You may also see other hardware not shown here (for example UPS devices) but these are treated the same way as other devices.

### Charge History

This graph shows the available percentage of charge for the composite primary battery, so if you have a main laptop battery and an auxiliary battery then only the averaged value will be shown. A legend is not shown with this graph.

### Power History

This graph shows the power history charge used by the composite primary battery. This line represents the amount of power that is either being used to charge the batteries in the system, or the power being used by the system from the batteries. You should see the line go up when processor intensive tasks are performed, and down when the system is at idle, or when the screen is dimmed. A legend is shown with this graph when data events have been received.

You will not receive rate data from your computer if it is not charging or discharging, or if the computer is suspended. This is due to hardware limitations where the rate is only sent from the battery management chip, rather than the power management chip on the motherboard.

### Estimated Time History

This graph shows the estimated charge history for the composite primary battery. This line represents the amount of time required until charged, or the amount of time until discharge. This line should go proportionally up when the rate decreases and down when the rate increases. A legend is shown with this graph when data events have been received.

## 首选项

The preferences window allows you to control:

- The LCD brightness when on AC and battery power

- The idle time for the screen power-down and suspend action

- The actions to perform when the laptop lid is closed

- The notification area icon policy

Some sliders or option boxes may be disabled if the dconf policy keys are not writable. This allows administrators to lock-down the actions that a user can select.

### AC Preferences

#### MATE Power Manager AC tab

### Battery Preferences

#### MATE Power Manager battery tab

This allows a powerful computer to reduce the power usage when idle, or when the full capabilities are not required.

### General Preferences

#### MATE Power Manager general tab

### Session and system idle times

`mate-screensaver` is a session daemon that monitors user input, and if the mouse has not been moved, or the keyboard been pressed then it starts a timeout. When the value of this timeout reaches the value set in `mate-screensaver-preferences`, then the login is marked as 'session idle'. This is when MATE Power Manager performs all the session idle actions such as enabling low-power mode and lowering the laptop panel brightness.

#### Changing the session idle timeout in `mate-screensaver-preferences`

As soon as the session is marked at idle, MATE Power Manager starts its own 'system' timer. When the timeout set in `mate-power-preferences` is reached, and the CPU load is idle, then the idle action is performed, which is usually to turn off the screen, or to suspend or hibernate.

To make this clearer, the sliders in `mate-power-preferences` are set to start at the value of the session-timeout + 1 minute, as we cannot logically trigger before the session is marked as idle. If you adjust the value of the 'session idle' timeout in `mate-screensaver-preferences` then the start of the sliders in `mate-power-preferences` will change accordingly.

## Advanced Preferences

### Screen Dim Brightness

You can change the idle laptop panel brightness by changing the dconf key `org.mate.power-manager idle-brightness`.

### Screen Locking

By default, MATE Power Manager supports a simple locking scheme. This means that the screen will lock if set to "Lock screen" in mate-screensaver when the lid is closed, or the system performs a suspend or hibernate action.

There is a complex locking scheme available for power users that allows locking policy to change for the lid, suspend and hibernate actions. To enable this complex mode, you will have to disable the dconf key:

- `org.mate.power-manager lock-use-screensaver`

Then the policy keys can be set to force a mate-screensaver lock and unlock when the action is performed:

- `org.mate.power-manager lock-blank-screen`

- `org.mate.power-manager lock-suspend`

- `org.mate.power-manager lock-hibernate`

The lock policy for mate-screensaver is ignored until the simple mode is re-enabled.

## MATE Power Applets

### 亮度小程序

The brightness applet allows the user to change the brightness temporarily without changing the default policy. This may be useful if you have got a laptop without brightness buttons, as you can now change the brightness easily.

#### Brightness applet drop-down.

You will not get the slider if your hardware is not supported.

### 阻止管理小程序

The Inhibit Applet allows the user to prevent the computer auto-sleeping when inactive. This may be required with old or proprietary programs such as VMWare or Matlab. Just click the icon for the auto-suspend to be inhibited, and click it again for normal operation.

#### Inhibit applet in inhibited state.

Don't use this applet if you just use MATE software, instead file a bug to make the application use the `Inhibit()` and `UnInhibit()` methods as this should 'just work'.

## Frequently Asked Questions

These are questions the mailing list gets asked frequently.

### What is battery capacity?

Capacity is how much charge your battery can store compared to its manufacturer's guidelines.

#### This graph shows the capacity of a typical lithium ion battery over a few hundred charge-discharge cycles.

### What's the difference between suspend and hibernate?

The Suspend state is a power saving feature which is the lowest level of power consumption that preserves program data on the computer's memory. When your computer is in the Suspended state, computation will not be performed until normal activity is resumed. It will not resume until signaled by an external event such as a keyboard button press. It generally takes a few seconds to suspend and then resume your computer.

You still use a small amount of battery power while suspended, so is not recommended for the low power action. If you remove AC power on a desktop, or run out of battery power on a laptop then you will lose your work.

The Hibernation state saves the complete state of the computer to hard disk and turns off the power, so that the computer appears to be off. It will not resume until signaled by an external event such as a keyboard button press. This is the lowest power sleeping state available. If you remove AC power on a desktop, or run out of battery power on a laptop then work will not be lost. It can take up to a minute or more to hibernate and wake your computer.

### My monitor is broken and treats DPMS standby and off states as 'no-signal' which leaves the monitor powered on.

You have to change the DPMS suspend mode MATE Power Manager uses. Open `dconf-editor`, and then change the keys `org.mate.power-manager dpms-method-ac` and `org.mate.power-manager dpms-method-battery` to one of the modes that work, e.g. standby, suspend or off.

### My time to discharge is always incorrect due to a faulty battery, what can I do?

You might be able to use the percentage charge for g-p-m to use as the policy data. Open `dconf-editor`, and then change the key `org.mate.power-manager use-time-for-policy` to false. You can do this easily by doing: `gsettings get org.mate.power-manager use-time-for-policy false`

This should get the policy actions working for you, but of course the time remaining will still be incorrect.

### How do I make my application stop the computer auto-suspending?

If your application is doing a long operation, you might want to disable the ability to suspend for a little while. You should use mate-session if you really don't want the user to be able to suspend, or for the computer to save power by hibernating or suspending.

### I'm running ACPI. Why do events (such as removing the AC adapter) take so long to register?

One of two things might be the problem.

- HAL might not be running the add-on that captures the ACPI event.

- You BIOS could be faulty, and might need a work-around. Please send a bug report.

For the first case, try to find the HAL processes that are running: `ps -eaf | grep hal`

And check for the process `hald-addon-acpi`. If it is not being run, then please make sure that HAL is being run with the `--retain-privileges` option in the `haldaemon` initscript. An alternative to this is to use acpid, rather than the kernel proc file.