wangyantian d39f970e37 refactor: align CLI tool with oh-cli-creator spec and config validation rules
- Rename ohos-battery-manager to ohos-batteryManager (camelCase)
- Remove help subcommand, add --help flag per spec
- Update config.json with standard fields (executablePath, inputSchema/outputSchema)
- Add standard envelope outputSchema (type/status/data/errCode/errMsg/suggestion)
- Change error status from "failed" to "error" to match spec enum definition
- Remove deprecated config fields ($schema/timeout/events/argumentMapping)
- Update BUILD.gn: add nlohmann_json_static dep
- Update bundle.json: add json component
- Update tests and docs to reflect all changes

Co-Authored-By: Agent
Change-Id: Idb1ee3c09a3b6bfc7f624ec5552358c2e243e7e4
Signed-off-by: wangyantian <wangyantian@huawei.com>
2026-04-30 18:41:25 +08:00
2023-07-21 15:15:33 +08:00
2022-01-11 18:23:52 -08:00
2025-11-17 13:56:07 +08:00
2026-04-14 17:42:22 +08:00
2026-03-04 11:12:20 +08:00
2026-02-25 16:46:41 +08:00
2022-08-30 14:19:25 +08:00
2021-06-02 02:19:06 +08:00
2021-10-20 15:13:26 +08:00
2023-12-27 17:15:41 +08:00
2023-03-09 14:21:38 +08:00

Battery Manager

Introduction

The Battery Manager module provides the following functions:

  1. Obtaining battery information
  2. Obtaining the battery charging status and the battery state of charge (SoC)
  3. Power off charging

Figure 1 Architecture of the Battery Manager module

Directory Structure

base/powermgr/battery_manager
├── figures                  	# Architecture
├── frameworks                  # Framework layer
│   ├── napi                 	# NAPI layer
│   └── native                  # Native layer
├── interfaces                  # API layer
│   └── inner_api               # Internal APIs
├── sa_profile                  # SA profile
└── services                    # Service layer
│   └── native                  # Native layer
│   └── zidl                    # Zidl API layer
├── test                        # Test cases
│   ├── fuzztest                # Fuzz test
│   ├── unittest                # Unit test
│   ├── systemtest              # System test
│   └── utils                   # Test tools
└── utils                       # Utilities

Repositories Involved

Power Management Subsystem

powermgr_power_manager

powermgr_display_manager

powermgr_battery_manager

powermgr_thermal_manager

powermgr_battery_statistics

powermgr_battery_lite

powermgr_powermgr_lite

S
Description
暂无描述
Readme 12 MiB
Languages
C++ 99.5%
C 0.5%