当前位置: 首页 > article >正文

usb通过hdc连接鸿蒙next的常用指令

参考官方 注册报名https://www.hiascend.com/developer/activities/details/44de441ef599450596131c8cb52f7f8c/signup?channelCode=S1&recommended=496144

hdc-调试命令-调测调优-系统 - 华为HarmonyOS开发者icon-default.png?t=O83Ahttps://developer.huawei.com/consumer/cn/doc/harmonyos-guides-V13/hdc-V13

hdc是用于Openharmony的命令行调试工具,这边将它与android的adb进行对应

OpenharmonyAndroid
Ability        Activity
bundlepackageName

用中文说的话就是 以前adb 获取的包名,在纯血鸿蒙中就叫bundle ,

android 运行的activity 现在叫 ability

关于 hdc 的服务,在任务管理器中可以看到

hdc进程带有参数  dummy -l 3-s::ffff:127.0.0.1:8710 -m 

参数解释

    dummy

        表示运行 HDC 工具的 dummy 子命令。

        dummy 通常用于模拟或测试连接,可能与特定调试场景相关。

    -l 3

        设置日志等级(Log Level)。

        具体级别通常按数字区分:

            0: 不输出日志。

            1: 输出错误日志。

            2: 输出警告和错误日志。

            3: 输出详细的调试日志(通常是最详细的)。

    -s ::ffff:127.0.0.1:8710

        指定连接的目标地址和端口。

        ::ffff:127.0.0.1 是 IPv4 地址(127.0.0.1)在 IPv6 映射中的表示方式。

            127.0.0.1: 指向本地回环地址(localhost)。

            8710: 指定的端口号。

        该参数通常用于指定设备或服务的连接地址,表示将 HDC 连接到本地设备或服务。

    -m

        可能是一个标志参数(Flag),通常表示启用特定模式或功能。

        具体作用需要查看 hdc.exe 的文档或帮助信息。

常用命令

微信(com.tencent.wechat)为例

1、查看系统安装了哪些应用

hdc shell bm dump -a

2、查询该应用的详细信息

hdc shell bm dump -n com.tencent.wechat -u 100


得到下面一坨东东

com.tencent.wechat:
{
    "appId": "com.tencent.wechat_BDzt+HA+eicpXsiMTgQzrRAEE6KUDZUCzKE42ck22zI8VHF5r6G6ZGj8fMCmPOnf/3U5rnRlUcgYKwTA7ZEDnyg=",
    "appIdentifier": "5765880207854244859",
    "appIndex": 0,
    "applicationInfo": {
        "GWPAsanEnabled": false,
        "accessTokenId": 537063932,
        "accessTokenIdEx": 537063932,
        "accessible": false,
        "allowAppRunWhenDeviceFirstLocked": false,
        "allowCommonEvent": [],
        "allowEnableNotification": false,
        "apiCompatibleVersion": 50001013,
        "apiReleaseType": "Release",
        "apiTargetVersion": 50001013,
        "appDetailAbilityLibraryPath": "",
        "appDistributionType": "app_gallery",
        "appEnvironments": [
            {
                "name": "ASAN_OPTIONS",
                "value": "detect_stack_use_after_return=true alloc_dealloc_mismatch=0 detect_container_overflow=0"
            }
        ],
        "appIndex": 0,
        "appPrivilegeLevel": "normal",
        "appProvisionType": "release",
        "appQuickFix": {
            "bundleName": "",
            "deployedAppqfInfo": {
                "cpuAbi": "",
                "hqfInfos": [],
                "nativeLibraryPath": "",
                "type": 0,
                "versionCode": 0,
                "versionName": ""
            },
            "deployingAppqfInfo": {
                "cpuAbi": "",
                "hqfInfos": [],
                "nativeLibraryPath": "",
                "type": 0,
                "versionCode": 0,
                "versionName": ""
            },
            "versionCode": 0,
            "versionName": ""
        },
        "applicationFlags": 1,
        "applicationReservedFlag": 1,
        "arkNativeFileAbi": "",
        "arkNativeFilePath": "",
        "asanEnabled": false,
        "asanLogPath": "",
        "associatedWakeUp": false,
        "bundleName": "com.tencent.wechat",
        "bundleType": 0,
        "cacheDir": "",
        "cloudFileSyncEnabled": false,
        "codePath": "/data/app/el1/bundle/public/com.tencent.wechat",
        "compileSdkType": "HarmonyOS",
        "compileSdkVersion": "5.0.1.112",
        "configuration": "",
        "cpuAbi": "arm64-v8a",
        "crowdtestDeadline": -1,
        "dataBaseDir": "/data/app/el2/database/com.tencent.wechat",
        "dataDir": "",
        "debug": false,
        "description": "",
        "descriptionId": 0,
        "descriptionResource": {
            "bundleName": "com.tencent.wechat",
            "id": 0,
            "moduleName": "entry"
        },
        "deviceId": "PHONE-001",
        "distributedNotificationEnabled": true,
        "enabled": true,
        "entityType": "unspecified",
        "entryDir": "",
        "entryModuleName": "",
        "fingerprint": "9D4F2B7B0310D637EF99505FAF5FC7C5B8FF16C84B44C4BEABA4F8859BB45912",
        "flags": 0,
        "formVisibleNotify": false,
        "hideDesktopIcon": false,
        "hnpPackages": {},
        "hwasanEnabled": false,
        "icon": "",
        "iconId": 788529153,
        "iconPath": "$media:app_icon",
        "iconResource": {
            "bundleName": "com.tencent.wechat",
            "id": 788529153,
            "moduleName": "entry"
        },
        "installSource": "com.huawei.hmsapp.appgallery",
        "isCompressNativeLibs": true,
        "isFreeInstallApp": false,
        "isLauncherApp": false,
        "isSystemApp": false,
        "keepAlive": false,
        "label": "$string:app_name",
        "labelId": 788529156,
        "labelResource": {
            "bundleName": "com.tencent.wechat",
            "id": 788529156,
            "moduleName": "entry"
        },
        "maxChildProcess": 1,
        "metaData": {},
        "metadata": {},
        "minCompatibleVersionCode": 1049386,
        "moduleInfos": [
            {
                "moduleName": "entry",
                "moduleSourceDir": "",
                "preloads": []
            }
        ],
        "moduleSourceDirs": [],
        "multiAppMode": {
            "maxCount": 1,
            "multiAppModeType": 2
        },
        "multiProjects": false,
        "name": "com.tencent.wechat",
        "nativeLibraryPath": "libs/arm64",
        "needAppDetail": false,
        "organization": "腾讯科技(北京)有限公司",
        "overlayState": 0,
        "permissions": [],
        "process": "com.tencent.wechat",
        "removable": true,
        "resourcesApply": [],
        "runningResourcesApply": false,
        "signatureKey": "",
        "singleton": false,
        "supportedModes": 0,
        "targetBundleList": [],
        "targetBundleName": "",
        "targetPriority": 0,
        "tsanEnabled": false,
        "ubsanEnabled": false,
        "uid": 20020196,
        "userDataClearable": true,
        "vendor": "Tencent",
        "versionCode": 1049386,
        "versionName": "1.0.3.42"
    },
    "compatibleVersion": 50001013,
    "cpuAbi": "",
    "defPermissions": [],
    "description": "",
    "entryInstallationFree": false,
    "entryModuleName": "entry",
    "gid": 20020196,
    "hapModuleInfos": [
        {
            "abilityInfos": [
                {
                    "appIndex": 0,
                    "applicationName": "com.tencent.wechat",
                    "backgroundModes": 130,
                    "bundleName": "com.tencent.wechat",
                    "codePath": "",
                    "compileMode": 1,
                    "configChanges": [],
                    "continuable": false,
                    "continueBundleName": [],
                    "continueType": [
                        "EntryAbility"
                    ],
                    "defaultFormHeight": 0,
                    "defaultFormWidth": 0,
                    "description": "$string:EntryAbility_desc",
                    "descriptionId": 788529155,
                    "deviceCapabilities": [],
                    "deviceTypes": [
                        "phone",
                        "tablet",
                        "2in1"
                    ],
                    "enabled": true,
                    "excludeFromDock": false,
                    "excludeFromMissions": false,
                    "extensionAbilityType": 255,
                    "formEnabled": false,
                    "formEntity": 0,
                    "hapPath": "/data/app/el1/bundle/public/com.tencent.wechat/entry.hap",
                    "iconId": 788529153,
                    "iconPath": "$media:app_icon",
                    "isLauncherAbility": false,
                    "isModuleJson": true,
                    "isNativeAbility": false,
                    "isStageBasedModel": true,
                    "isolationProcess": false,
                    "kind": "",
                    "label": "$string:EntryAbility_label",
                    "labelId": 788529156,
                    "launchMode": 0,
                    "maxWindowHeight": 0,
                    "maxWindowRatio": 0,
                    "maxWindowWidth": 0,
                    "metaData": {
                        "customizeData": []
                    },
                    "metadata": [],
                    "minFormHeight": 0,
                    "minFormWidth": 0,
                    "minWindowHeight": 0,
                    "minWindowRatio": 0,
                    "minWindowWidth": 0,
                    "moduleName": "entry",
                    "name": "EntryAbility",
                    "orientation": 0,
                    "orientationId": 0,
                    "package": "entry",
                    "permissions": [],
                    "preferMultiWindowOrientation": "default",
                    "priority": 0,
                    "process": "",
                    "readPermission": "",
                    "recoverable": false,
                    "removeMissionAfterTerminate": false,
                    "resourcePath": "/data/app/el1/bundle/public/com.tencent.wechat/entry/resources.index",
                    "skills": [
                        {
                            "actions": [
                                "action.system.home",
                                "action.ohos.push.listener"
                            ],
                            "domainVerify": false,
                            "entities": [
                                "entity.system.home"
                            ],
                            "permissions": [],
                            "uris": []
                        },
                        {
                            "actions": [
                                "action.system.home",
                                "ohos.want.action.viewData"
                            ],
                            "domainVerify": false,
                            "entities": [
                                "entity.system.home"
                            ],
                            "permissions": [],
                            "uris": [
                                {
                                    "host": "",
                                    "linkFeature": "",
                                    "maxFileSupported": 0,
                                    "path": "",
                                    "pathRegex": "",
                                    "pathStartWith": "",
                                    "port": "",
                                    "scheme": "weixin",
                                    "type": "",
                                    "utd": ""
                                }
                            ]
                        },
                        {
                            "actions": [
                                "action.system.home",
                                "ohos.want.action.viewData"
                            ],
                            "domainVerify": false,
                            "entities": [
                                "entity.system.home"
                            ],
                            "permissions": [],
                            "uris": [
                                {
                                    "host": "wap",
                                    "linkFeature": "",
                                    "maxFileSupported": 0,
                                    "path": "",
                                    "pathRegex": "",
                                    "pathStartWith": "",
                                    "port": "",
                                    "scheme": "weixin",
                                    "type": "",
                                    "utd": ""
                                },
                                {
                                    "host": "betalogin",
                                    "linkFeature": "",
                                    "maxFileSupported": 0,
                                    "path": "",
                                    "pathRegex": "",
                                    "pathStartWith": "",
                                    "port": "",
                                    "scheme": "weixin",
                                    "type": "",
                                    "utd": ""
                                }
                            ]
                        },
                        {
                            "actions": [
                                "ohos.want.action.sendData"
                            ],
                            "domainVerify": false,
                            "entities": [
                                "entity.system.home"
                            ],
                            "permissions": [],
                            "uris": [
                                {
                                    "host": "",
                                    "linkFeature": "",
                                    "maxFileSupported": 1,
                                    "path": "",
                                    "pathRegex": "",
                                    "pathStartWith": "",
                                    "port": "",
                                    "scheme": "file",
                                    "type": "",
                                    "utd": "general.image"
                                },
                                {
                                    "host": "",
                                    "linkFeature": "",
                                    "maxFileSupported": 1,
                                    "path": "",
                                    "pathRegex": "",
                                    "pathStartWith": "",
                                    "port": "",
                                    "scheme": "file",
                                    "type": "",
                                    "utd": "general.video"
                                }
                            ]
                        }
                    ],
                    "srcEntrance": "./ets/entryability/EntryAbility.ets",
                    "srcLanguage": "js",
                    "srcPath": "",
                    "startWindowBackground": "$color:entry_start_window_background",
                    "startWindowBackgroundId": 788529168,
                    "startWindowIcon": "$media:start_window_icon",
                    "startWindowIconId": 788529170,
                    "supportExtNames": [],
                    "supportMimeTypes": [],
                    "supportPipMode": false,
                    "supportWindowMode": [
                        0,
                        1,
                        2
                    ],
                    "targetAbility": "",
                    "theme": "",
                    "type": 1,
                    "uid": -1,
                    "unclearableMission": false,
                    "uri": "",
                    "visible": true,
                    "writePermission": ""
                }
            ],
            "aotCompileStatus": 0,
            "appEnvironments": [],
            "appStartup": "",
            "backgroundImg": "",
            "buildHash": "",
            "bundleName": "com.tencent.wechat",
            "colorMode": -1,
            "compileMode": 1,
            "compressNativeLibs": true,
            "cpuAbi": "",
            "deliveryWithInstall": true,
            "dependencies": [],
            "description": "$string:module_desc",
            "descriptionId": 788529166,
            "deviceTypes": [
                "phone",
                "tablet",
                "2in1"
            ],
            "extensionInfos": [
                {
                    "appIndex": 0,
                    "bundleName": "com.tencent.wechat",
                    "compileMode": 1,
                    "dataGroupIds": [],
                    "description": "",
                    "descriptionId": 0,
                    "enabled": true,
                    "extensionProcessMode": -1,
                    "extensionTypeName": "backup",
                    "hapPath": "/data/app/el1/bundle/public/com.tencent.wechat/entry.hap",
                    "icon": "",
                    "iconId": 0,
                    "label": "",
                    "labelId": 0,
                    "metadata": [
                        {
                            "name": "ohos.extension.backup",
                            "resource": "$profile:backup_config",
                            "value": ""
                        }
                    ],
                    "moduleName": "entry",
                    "name": "EntryBackupAbility",
                    "needCreateSandbox": false,
                    "permissions": [],
                    "priority": 0,
                    "process": "com.tencent.wechat:backup",
                    "readPermission": "",
                    "resourcePath": "/data/app/el1/bundle/public/com.tencent.wechat/entry/resources.index",
                    "skills": [],
                    "srcEntrance": "./ets/entrybackupability/EntryBackupAbility.ets",
                    "type": 9,
                    "uid": -1,
                    "uri": "",
                    "validDataGroupIds": [],
                    "visible": false,
                    "writePermission": ""
                },
                {
                    "appIndex": 0,
                    "bundleName": "com.tencent.wechat",
                    "compileMode": 1,
                    "dataGroupIds": [],
                    "description": "PushExtAbility test",
                    "descriptionId": 0,
                    "enabled": true,
                    "extensionProcessMode": -1,
                    "extensionTypeName": "remoteNotification",
                    "hapPath": "/data/app/el1/bundle/public/com.tencent.wechat/entry.hap",
                    "icon": "",
                    "iconId": 0,
                    "label": "",
                    "labelId": 0,
                    "metadata": [],
                    "moduleName": "entry",
                    "name": "RemoteNotificationExtAbility",
                    "needCreateSandbox": false,
                    "permissions": [],
                    "priority": 0,
                    "process": "com.tencent.wechat:remoteNotification",
                    "readPermission": "",
                    "resourcePath": "/data/app/el1/bundle/public/com.tencent.wechat/entry/resources.index",
                    "skills": [
                        {
                            "actions": [
                                "action.hms.push.extension.remotenotification"
                            ],
                            "domainVerify": false,
                            "entities": [],
                            "permissions": [],
                            "uris": []
                        }
                    ],
                    "srcEntrance": "./ets/entryability/PushExtAbility.ets",
                    "type": 260,
                    "uid": -1,
                    "uri": "",
                    "validDataGroupIds": [],
                    "visible": false,
                    "writePermission": ""
                }
            ],
            "fileContextMenu": "",
            "hapPath": "/data/app/el1/bundle/public/com.tencent.wechat/entry.hap",
            "hashValue": "6cfc97af5e5ff90edb57e6f1e53c79132326ed7c3a8ece377960a124fca02bfe",
            "hqfInfo": {
                "cpuAbi": "",
                "hapSha256": "",
                "hqfFilePath": "",
                "moduleName": "",
                "nativeLibraryPath": "",
                "type": 0
            },
            "iconId": 788529153,
            "iconPath": "$media:app_icon",
            "installationFree": false,
            "isLibIsolated": false,
            "isModuleJson": true,
            "isRemovable": {},
            "isStageBasedModel": true,
            "isolationMode": 0,
            "label": "$string:EntryAbility_label",
            "labelId": 788529156,
            "mainAbility": "EntryAbility",
            "mainElementName": "EntryAbility",
            "metadata": [
                {
                    "name": "client_id",
                    "resource": "",
                    "value": "110859259"
                },
                {
                    "name": "half_leading",
                    "resource": "",
                    "value": "true"
                }
            ],
            "moduleName": "entry",
            "moduleSourceDir": "",
            "moduleType": 1,
            "name": "entry",
            "nativeLibraryFileNames": [],
            "nativeLibraryPath": "",
            "overlayModuleInfos": [],
            "package": "entry",
            "packageName": "entry",
            "pages": "",
            "preloads": [],
            "process": "com.tencent.wechat",
            "proxyDatas": [],
            "reqCapabilities": [],
            "resourcePath": "/data/app/el1/bundle/public/com.tencent.wechat/entry/resources.index",
            "routerArray": [
                {
                    "buildFunction": "WAPageBuilder",
                    "bundleName": "com.tencent.wechat",
                    "customData": "",
                    "data": {},
                    "moduleName": "entry",
                    "name": "ChildPage",
                    "ohmurl": "@normalized:N&&&feat_weapp/src/main/ets/core/page/WAPage&1.0.0",
                    "pageSourceFile": "src/main/ets/core/page/WAPage.ets"
                },
                {
                    "buildFunction": "WALoadingPageBuilder",
                    "bundleName": "com.tencent.wechat",
                    "customData": "",
                    "data": {},
                    "moduleName": "entry",
                    "name": "WALoadingPage",
                    "ohmurl": "@normalized:N&&&feat_weapp/src/main/ets/core/page/WALoadingPage&1.0.0",
                    "pageSourceFile": "src/main/ets/core/page/WALoadingPage.ets"
                }
            ],
            "routerMap": "$profile:default-router-map",
            "srcEntrance": "./ets/abilitystate/WXAbilityStage.ets",
            "srcPath": "",
            "supportedModes": 0,
            "uiSyntax": "hml",
            "upgradeFlag": 0,
            "virtualMachine": ""
        }
    ],
    "hapModuleNames": [
        "entry"
    ],
    "installTime": 1736141906722,
    "isDifferentName": false,
    "isKeepAlive": false,
    "isNativeApp": false,
    "isNewVersion": true,
    "isPreInstallApp": false,
    "jointUserId": "",
    "label": "",
    "mainEntry": "entry",
    "maxSdkVersion": -1,
    "minCompatibleVersionCode": 1049386,
    "minSdkVersion": -1,
    "moduleDirs": [
        "/data/app/el1/bundle/public/com.tencent.wechat/entry"
    ],
    "moduleNames": [
        "entry"
    ],
    "modulePublicDirs": [
        ""
    ],
    "moduleResPaths": [
        "/data/app/el1/bundle/public/com.tencent.wechat/entry/resources.index"
    ],
    "name": "com.tencent.wechat",
    "oldAppIds": [
        "com.tencent.wechat_BDzt+HA+eicpXsiMTgQzrRAEE6KUDZUCzKE42ck22zI8VHF5r6G6ZGj8fMCmPOnf/3U5rnRlUcgYKwTA7ZEDnyg="
    ],
    "overlayBundleInfos": [],
    "overlayType": 3,
    "releaseType": "Release",
    "reqPermissionDetails": [
        {
            "moduleName": "entry",
            "name": "ohos.permission.ACCELEROMETER",
            "reason": "$string:request_accelerometer_permission_reason",
            "reasonId": 788530365,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "inuse"
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.ACCESS_BLUETOOTH",
            "reason": "$string:permission_reason_access_bluetooth",
            "reasonId": 788530359,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "inuse"
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.APPROXIMATELY_LOCATION",
            "reason": "$string:Permission_APPROXIMATELY_LOCATION_reason",
            "reasonId": 788529982,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "inuse"
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.APP_TRACKING_CONSENT",
            "reason": "$string:Permission_APP_TRACKING_CONSENT_reason",
            "reasonId": 788529157,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "inuse"
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.CAMERA",
            "reason": "$string:request_permission_camera_reason",
            "reasonId": 788529167,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "inuse"
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.GET_NETWORK_INFO",
            "reason": "$string:Permission_GET_NETWORK_INFO_reason",
            "reasonId": 788529158,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "inuse"
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.GET_WIFI_INFO",
            "reason": "",
            "reasonId": 0,
            "usedScene": {
                "abilities": [],
                "when": ""
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.GYROSCOPE",
            "reason": "$string:request_gyroscope_permission_reason",
            "reasonId": 788530366,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "inuse"
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.INTERNET",
            "reason": "$string:Permission_INTERNET_reason",
            "reasonId": 788529159,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "inuse"
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.KEEP_BACKGROUND_RUNNING",
            "reason": "$string:Permission_KEEP_BACKGROUND_RUNNING_reason",
            "reasonId": 788529160,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "always"
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.LOCATION",
            "reason": "$string:request_permission_location",
            "reasonId": 788530369,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "inuse"
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.MICROPHONE",
            "reason": "$string:request_permission_mic_reason",
            "reasonId": 788530907,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "inuse"
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.PRIVACY_WINDOW",
            "reason": "$string:Permission_PRIVACY_WINDOW_reason",
            "reasonId": 788529161,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "inuse"
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.READ_CALENDAR",
            "reason": "$string:permission_reason_read_calendar",
            "reasonId": 788530360,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "inuse"
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.READ_PASTEBOARD",
            "reason": "$string:request_pasteboard_permission_reason",
            "reasonId": 788530367,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "inuse"
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.RUNNING_LOCK",
            "reason": "$string:Permission_PROXIMITY_RUNNING_LOCK_reason",
            "reasonId": 788529162,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "inuse"
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.SET_WIFI_INFO",
            "reason": "$string:permission_reason_set_wifi_info",
            "reasonId": 788530361,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "inuse"
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.STORE_PERSISTENT_DATA",
            "reason": "$string:Permission_STORE_PERSISTENT_DATA_reason",
            "reasonId": 788529163,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "inuse"
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.VIBRATE",
            "reason": "$string:Permission_VIBRATE_reason",
            "reasonId": 788529164,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "inuse"
            }
        },
        {
            "moduleName": "entry",
            "name": "ohos.permission.WRITE_CALENDAR",
            "reason": "$string:permission_reason_write_calendar",
            "reasonId": 788530362,
            "usedScene": {
                "abilities": [
                    "EntryAbility"
                ],
                "when": "inuse"
            }
        }
    ],
    "reqPermissionStates": [
        0,
        -1,
        -1,
        -1,
        -1,
        0,
        0,
        0,
        0,
        0,
        -1,
        -1,
        0,
        -1,
        -1,
        0,
        0,
        0,
        0,
        -1
    ],
    "reqPermissions": [
        "ohos.permission.ACCELEROMETER",
        "ohos.permission.ACCESS_BLUETOOTH",
        "ohos.permission.APPROXIMATELY_LOCATION",
        "ohos.permission.APP_TRACKING_CONSENT",
        "ohos.permission.CAMERA",
        "ohos.permission.GET_NETWORK_INFO",
        "ohos.permission.GET_WIFI_INFO",
        "ohos.permission.GYROSCOPE",
        "ohos.permission.INTERNET",
        "ohos.permission.KEEP_BACKGROUND_RUNNING",
        "ohos.permission.LOCATION",
        "ohos.permission.MICROPHONE",
        "ohos.permission.PRIVACY_WINDOW",
        "ohos.permission.READ_CALENDAR",
        "ohos.permission.READ_PASTEBOARD",
        "ohos.permission.RUNNING_LOCK",
        "ohos.permission.SET_WIFI_INFO",
        "ohos.permission.STORE_PERSISTENT_DATA",
        "ohos.permission.VIBRATE",
        "ohos.permission.WRITE_CALENDAR"
    ],
    "routerArray": [
        {
            "buildFunction": "WAPageBuilder",
            "bundleName": "com.tencent.wechat",
            "customData": "",
            "data": {},
            "moduleName": "entry",
            "name": "ChildPage",
            "ohmurl": "@normalized:N&&&feat_weapp/src/main/ets/core/page/WAPage&1.0.0",
            "pageSourceFile": "src/main/ets/core/page/WAPage.ets"
        },
        {
            "buildFunction": "WALoadingPageBuilder",
            "bundleName": "com.tencent.wechat",
            "customData": "",
            "data": {},
            "moduleName": "entry",
            "name": "WALoadingPage",
            "ohmurl": "@normalized:N&&&feat_weapp/src/main/ets/core/page/WALoadingPage&1.0.0",
            "pageSourceFile": "src/main/ets/core/page/WALoadingPage.ets"
        }
    ],
    "seInfo": "",
    "singleton": false,
    "targetVersion": 50001013,
    "uid": 20020196,
    "updateTime": 1736465427604,
    "userInfo": [
        {
            "accessTokenId": 537063932,
            "accessTokenIdEx": 537063932,
            "bundleName": "com.tencent.wechat",
            "bundleUserInfo": {
                "disabledAbilities": [],
                "enabled": true,
                "overlayState": [],
                "setEnabledCaller": "",
                "userId": 100
            },
            "cloneInfos": {},
            "gids": [
                20020196
            ],
            "installTime": 1736141906722,
            "isRemovable": true,
            "keyId": "",
            "uid": 20020196,
            "updateTime": 1736465427604
        }
    ],
    "vendor": "Tencent",
    "versionCode": 1049386,
    "versionName": "1.0.3.42"
}

顶层字段

字段名称含义
appId应用程序的唯一标识符,通常由系统生成,用于标识应用。
appIdentifier应用的唯一标识符,与 appId 类似,用于应用管理。
appIndex应用索引编号,在多个应用程序中用于标识应用的顺序。
applicationInfo应用的详细信息,包含更多配置和元数据,详细字段见下文。
compatibleVersion应用程序的兼容版本,用于表示该应用适配的最小 API 版本。
cpuAbi应用支持的 CPU 架构,例如 arm64-v8a 表示支持 64 位 ARM 架构。
hapModuleInfos应用的模块信息,列出了所有 HAP 模块及其包含的能力。
installTime应用的安装时间(时间戳)。
updateTime应用的最后更新时间(时间戳)。
name应用的包名(bundleName),唯一标识应用程序的包名称。
vendor应用的供应商信息,例如腾讯公司。
versionCode应用的版本号(整数),表示软件版本的递增编号,用于更新判断。
versionName应用的版本名称(字符串),用户可见的版本号。

applicationInfo 字段

该字段包含了应用的详细信息:

字段名称含义
GWPAsanEnabled是否启用 AddressSanitizer(ASan)调试工具,用于检测内存问题。
accessible表示应用是否可访问,通常用于权限控制。
allowAppRunWhenDeviceFirstLocked是否允许应用在设备首次锁定时运行。
apiCompatibleVersion应用程序的兼容 API 版本。
apiTargetVersion应用的目标 API 版本。
appDistributionType应用的分发类型,例如 app_gallery 表示通过应用市场分发。
bundleName应用包名,唯一标识应用。
codePath应用程序代码所在的路径。
compileSdkType应用编译时的 SDK 类型(如 HarmonyOS)。
compileSdkVersion编译时使用的 SDK 版本号。
cpuAbi应用支持的 CPU 架构,例如 arm64-v8a
dataBaseDir应用的数据文件存储路径。
debug是否处于调试模式。
enabled应用是否启用。
entryDir应用入口文件的路径。
flags应用标志位,用于表示特殊属性(如系统应用标志)。
iconPath应用图标的资源路径。
installSource应用的安装来源(如应用市场 appgallery)。
isSystemApp是否为系统应用。
label应用的显示名称(如微信)。
organization应用的组织或开发者名称。
permissions应用请求的权限列表。
process应用运行的默认进程名称。
uid应用的用户 ID(系统分配)。

hapModuleInfos 字段

该字段包含了应用 HAP 模块的信息(HarmonyOS 应用程序的功能模块):

字段名称含义
moduleNameHAP 模块的名称,例如 entry
abilityInfos模块中定义的功能能力,描述了应用的能力入口(如 EntryAbility)。
deviceTypes模块支持的设备类型,例如手机(phone)、平板(tablet)。
extensionInfos模块定义的扩展能力,例如远程通知扩展。
hapPathHAP 模块文件的路径。

permissions 字段

该字段定义了应用所请求的权限信息,例如:

权限名称含义
ohos.permission.INTERNET访问网络权限。
ohos.permission.LOCATION访问设备位置信息的权限。
ohos.permission.CAMERA使用摄像头权限。
ohos.permission.MICROPHONE使用麦克风权限。

routerArray 字段

该字段描述了应用程序的页面路由信息:

字段名称含义
name路由的名称,例如 ChildPage
buildFunction构建页面的函数,例如 WAPageBuilder
pageSourceFile页面源文件路径。


3、启动、结束微信

hdc shell aa start -a EntryAbility -b com.tencent.wechat

hdc shell aa force-stop  com.tencent.wechat

 4、截图并下载

命令:(注真机只能以jpeg为后缀,貌似只能放在/data/local/tmp/下)

hdc shell snapshot_display -f /data/local/tmp/screenshot.jpeg

hdc shell file recv/data/local/tmp/screenshot.jpeg  d:/

另外使用 

uitest screenCap

也可以 然后拉取方式同上个方法

5、手机常亮:

hdc shell power-shell setmode 602

6 获取系统信息集群详细信息。

hidumper-调试命令-调测调优-系统 - 华为HarmonyOS开发者


hdc shell hidumper -c

获取"base"或者"system"信息集群详细信息。

hidumper -c base
hidumper -c system

7获取当前系统参数

param get

 会得到下面一坨,注意如果查获取下面单独一个项的值 ,如const.product.name

则使用 

params get const.product.name
const.product.productid = 0x2D034C11
    const.product.model = ALN-AL00
    const.product.name = HUAWEI Mate 60 Pro
    const.product.dfx.fans.stage = 1
    const.product.os.dist.apiname = 5.0.1
    const.product.os.dist.version = 5.0.0
    const.product.os.dist.apiversion = 50001
    const.product.os.dist.releasetype = Release
    const.product.cpu.abilist = arm64-v8a
    const.product.hide = false
    const.product.hide.matchers = OpenHarmony-5
    const.product.hide.replacements = OpenHarmony-5
    const.product.brand = HUAWEI
    const.product.build.type = default
    const.product.build.user = default
    const.product.build.host = default
    const.product.build.date = default
    const.product.software.version = ALN-AL00 5.0.0.123(C00E120R4P24)
    const.product.cover_mode = 2
    const.product.baseappid = 20000
    const.product.cover_window_size = 806,0,1260,2720
    const.product.device_radius = 36
    const.product.manufacturer = HUAWEI
    const.product.bootloader.version = bootloader
    const.product.incremental.version = default
    const.product.hardwareversion = HL1CMSM
    const.product.firstapiversion = 1
    const.product.hardwareprofile = default
    const.product.device_authentication = HWALN
    const.ohos.version.security_patch = 2025/01/01
    const.ohos.version.certified = OpenHarmony 5.0.1
    const.ohos.releasetype = Release
    const.ohos.apiversion = 13
    const.ohos.fullname = OpenHarmony-5.0.1.120
    const.ohos.buildroothash = default
    const.build.description = ALN-AL00-user 205.0.0 HUAWEIALN-AL00 123-CHN-LGRP1 release-keys
    const.build.product = ALN
    const.build.vendor.date = 2024-12-31 14:36:55
    const.build.vendor.date.utc = 1735598215155
    const.build.ver.physical = ALN-AL00 205.0.0.123(C00E120R4P24)
    const.build.system.date = 2024-12-31 15:34:36
    const.build.system.date.utc = 1735601676847
    const.build.sa_sdk_version = arm64_10.2.5.0
    const.SystemCapability.AI.AICaption = true
    const.SystemCapability.AI.AiEngine = true
    const.SystemCapability.AI.Face.Comparator = true
    const.SystemCapability.AI.Face.Detector = true
    const.SystemCapability.AI.OCR.TextRecognition = true
    const.SystemCapability.AI.Search = true
    const.SystemCapability.AI.Vision.ImageCaption = true
    const.SystemCapability.AI.Vision.VisionBase = true
    const.SystemCapability.AI.Vision.ObjectDetection = true
    const.SystemCapability.AI.Vision.SkeletonDetection = true
    const.SystemCapability.AI.Vision.SubjectSegmentation = true
    const.SystemCapability.AI.Component.CardRecognition = true
    const.SystemCapability.AI.Component.DocScan = true
    const.SystemCapability.AI.Component.LivenessDetect = true
    const.SystemCapability.AI.Component.TextReader = true
    const.SystemCapability.AI.GenerateAI.LLM = true
    const.SystemCapability.AI.HiAIFoundation = true
    const.SystemCapability.AI.InsightIntent = true
    const.SystemCapability.AI.MindSporeLite = true
    const.SystemCapability.AI.TextToSpeech = true
    const.SystemCapability.AI.IntelligentKws.Core = true
    const.SystemCapability.AI.ImageAnalyzerOverlay = true
    const.SystemCapability.AI.IntelligentVoice.Core = true
    const.SystemCapability.AI.NaturalLanguage.TextProcessing = true
    const.SystemCapability.AI.SpeechRecognizer = true
    const.SystemCapability.AI.NeuralNetworkRuntime = true
    const.SystemCapability.AI.VisionImageAnalyzer = true
    const.SystemCapability.Ai.MindSpore = true
    const.SystemCapability.AREngine.Core = true
    const.SystemCapability.Ability.AbilityBase = true
    const.SystemCapability.Ability.AppStartup = true
    const.SystemCapability.Ability.Form = true
    const.SystemCapability.Ability.AbilityRuntime.AbilityCore = true
    const.SystemCapability.Ability.AbilityRuntime.Core = true
    const.SystemCapability.Ability.AbilityRuntime.FAModel = true
    const.SystemCapability.Ability.AbilityRuntime.Mission = true
    const.SystemCapability.Ability.AbilityRuntime.QuickFix = true
    const.SystemCapability.Ability.AbilityTools.AbilityAssistant = true
    const.SystemCapability.Ability.AppExtension.PhotoEditorExtension = true
    const.SystemCapability.Ability.DistributedAbilityManager = true
    const.SystemCapability.Account.AppAccount = true
    const.SystemCapability.Account.OsAccount = true
    const.SystemCapability.ArkUI.ArkUI.Full = true
    const.SystemCapability.ArkUI.ArkUI.Lite = true
    const.SystemCapability.ArkUI.ArkUI.Napi = true
    const.SystemCapability.ArkUI.ArkUI.Libuv = true
    const.SystemCapability.ArkUI.UiAppearance = true
    const.SystemCapability.ArkUi.Graphics3D = true
    const.SystemCapability.Base = true
    const.SystemCapability.Game.GameService.GamePlayer = true
    const.SystemCapability.Map.Core = true
    const.SystemCapability.USB.USBManager = true
    const.SystemCapability.Web.Webview.Core = true
    const.SystemCapability.XTS.DeviceAttest = true
    const.SystemCapability.Msdp.DeviceStatus.Cooperate = true
    const.SystemCapability.Msdp.DeviceStatus.Drag = true
    const.SystemCapability.Msdp.DeviceStatus.Stationary = true
    const.SystemCapability.Msdp.Geofence = true
    const.SystemCapability.Msdp.Motion = true
    const.SystemCapability.Msdp.Movement = true
    const.SystemCapability.Msdp.Timeline = true
    const.SystemCapability.Msdp.MultiModalAwareness = true
    const.SystemCapability.Msdp.SpatialAwareness = true
    const.SystemCapability.Msdp.UserStatusAwareness = true
    const.SystemCapability.Push.PushService = true
    const.SystemCapability.Test.UiTest = true
    const.SystemCapability.Cloud.HiAnalytics = true
    const.SystemCapability.Print.PrintFramework = true
    const.SystemCapability.Utils.Lang = true
    const.SystemCapability.Global.I18n = true
    const.SystemCapability.Global.I18nExt = true
    const.SystemCapability.Global.ResourceManager = true
    const.SystemCapability.Health.Cooperation = true
    const.SystemCapability.Health.HealthStore = true
    const.SystemCapability.Health.WearEngine = true
    const.SystemCapability.Health.HealthService = true
    const.SystemCapability.Stylus.Handwrite = true
    const.SystemCapability.Update.DistributedUpdateEngine = true
    const.SystemCapability.Update.UpdateService = true
    const.SystemCapability.Window.SessionManager = true
    const.SystemCapability.Graphic.ApsManager.Resolution = true
    const.SystemCapability.Graphic.Graphic2D.ColorManager.Core = true
    const.SystemCapability.Graphic.Graphic2D.EGL = true
    const.SystemCapability.Graphic.Graphic2D.GLES2 = true
    const.SystemCapability.Graphic.Graphic2D.GLES3 = true
    const.SystemCapability.Graphic.Graphic2D.WebGL = true
    const.SystemCapability.Graphic.Graphic2D.NativeBuffer = true
    const.SystemCapability.Graphic.Graphic2D.NativeImage = true
    const.SystemCapability.Graphic.Graphic2D.NativeVsync = true
    const.SystemCapability.Graphic.Graphic2D.WebGL2 = true
    const.SystemCapability.Graphic.Graphic2D.NativeWindow = true
    const.SystemCapability.Graphic.Graphic2D.HyperGraphicManager = true
    const.SystemCapability.Graphic.Graphic2D.NativeDrawing = true
    const.SystemCapability.Graphic.Vulkan = true
    const.SystemCapability.Graphic.XEngine = true
    const.SystemCapability.Payment.ECNYPaymentService = true
    const.SystemCapability.Payment.IAP = true
    const.SystemCapability.Payment.PaymentService = true
    const.SystemCapability.Payment.Wallet = true
    const.SystemCapability.Request.FileTransferAgent = true
    const.SystemCapability.Sensors.MiscDevice = true
    const.SystemCapability.Sensors.MiscDevice.Lite = true
    const.SystemCapability.Sensors.Sensor = true
    const.SystemCapability.Sensors.Sensor.Lite = true
    const.SystemCapability.Startup.SystemInfo = true
    const.SystemCapability.Startup.SystemInfo.Lite = true
    const.SystemCapability.UserIAM.FingerprintAuthExt = true
    const.SystemCapability.UserIAM.UserAuth.Core = true
    const.SystemCapability.UserIAM.UserAuth.FaceAuth = true
    const.SystemCapability.UserIAM.UserAuth.PinAuth = true
    const.SystemCapability.UserIAM.UserAuth.FingerprintAuth = true
    const.SystemCapability.Weather.Core = true
    const.SystemCapability.Graphics.Drawing = true
    const.SystemCapability.HuaweiID.InvoiceAssistant = true
    const.SystemCapability.LiveView.LiveViewService = true
    const.SystemCapability.Location.Location.Core = true
    const.SystemCapability.Location.Location.Gnss = true
    const.SystemCapability.Location.Location.Lite = true
    const.SystemCapability.Location.Location.Geocoder = true
    const.SystemCapability.Location.Location.Geofence = true
    const.SystemCapability.Ringtone.Core = true
    const.SystemCapability.Security.AccessToken = true
    const.SystemCapability.Security.AppLock = true
    const.SystemCapability.Security.Asset = true
    const.SystemCapability.Security.Cert = true
    const.SystemCapability.Security.FIDO = true
    const.SystemCapability.Security.Huks.AttestKeyExt = true
    const.SystemCapability.Security.Huks.Core = true
    const.SystemCapability.Security.Huks.Extension = true
    const.SystemCapability.Security.Ifaa = true
    const.SystemCapability.Security.SOTER = true
    const.SystemCapability.Security.Cipher = true
    const.SystemCapability.Security.CodeProtect = true
    const.SystemCapability.Security.DeviceAuth = true
    const.SystemCapability.Security.TrustedRing = true
    const.SystemCapability.Security.ActivationLock = true
    const.SystemCapability.Security.PrivateSpace = true
    const.SystemCapability.Security.SafetyDetect = true
    const.SystemCapability.Security.SecurityGuard = true
    const.SystemCapability.Security.BusinessRiskIntelligentDetection = true
    const.SystemCapability.Security.CertificateManager = true
    const.SystemCapability.Security.CryptoFramework = true
    const.SystemCapability.Security.CryptoFramework.Cipher = true
    const.SystemCapability.Security.CryptoFramework.Kdf = true
    const.SystemCapability.Security.CryptoFramework.Key = true
    const.SystemCapability.Security.CryptoFramework.Key.AsymKey = true
    const.SystemCapability.Security.CryptoFramework.Key.SymKey = true
    const.SystemCapability.Security.CryptoFramework.Mac = true
    const.SystemCapability.Security.CryptoFramework.Rand = true
    const.SystemCapability.Security.CryptoFramework.KeyAgreement = true
    const.SystemCapability.Security.CryptoFramework.Signature = true
    const.SystemCapability.Security.CryptoFramework.MessageDigest = true
    const.SystemCapability.Security.DataLossPrevention = true
    const.SystemCapability.Security.DataTransitManager = true
    const.SystemCapability.Security.DeviceCertificate = true
    const.SystemCapability.Security.TrustedAppService.Core = true
    const.SystemCapability.Security.TrustedAppService.Location = true
    const.SystemCapability.Security.DeviceSecurityMode = true
    const.SystemCapability.Security.DeviceHealthAttestation = true
    const.SystemCapability.Security.DeviceSecurityLevel = true
    const.SystemCapability.Security.DlpCredentialService = true
    const.SystemCapability.Security.ScreenLockFileManager = true
    const.SystemCapability.Security.SecurityPrivacyServer = true
    const.SystemCapability.UIDesign.Core = true
    const.SystemCapability.UIDesign.HDSComponent.Core = true
    const.SystemCapability.Advertising.Ads = true
    const.SystemCapability.Advertising.OAID = true
    const.SystemCapability.ArkCompiler.JSVM = true
    const.SystemCapability.BarrierFree.Accessibility.Core = true
    const.SystemCapability.BarrierFree.Accessibility.Hearing = true
    const.SystemCapability.BarrierFree.Accessibility.Vision = true
    const.SystemCapability.CarService.DistributedEngine = true
    const.SystemCapability.CarService.NavigationInfo = true
    const.SystemCapability.FindDevice.FindNetwork = true
    const.SystemCapability.HiViewDFX.HiviewcareManager = true
    const.SystemCapability.HiViewDFX.Maintenance = true
    const.SystemCapability.HiviewDFX.HiAppEvent = true
    const.SystemCapability.HiviewDFX.HiChecker = true
    const.SystemCapability.HiviewDFX.HiCollie = true
    const.SystemCapability.HiviewDFX.HiDumper = true
    const.SystemCapability.HiviewDFX.HiLog = true
    const.SystemCapability.HiviewDFX.HiTrace = true
    const.SystemCapability.HiviewDFX.HiView.ChrLogService = true
    const.SystemCapability.HiviewDFX.HiView.LogService = true
    const.SystemCapability.HiviewDFX.Hiview = true
    const.SystemCapability.HiviewDFX.Hiview.FaultLogger = true
    const.SystemCapability.HiviewDFX.Hiview.LogLibrary = true
    const.SystemCapability.HiviewDFX.XPower = true
    const.SystemCapability.HiviewDFX.InfoSec = true
    const.SystemCapability.HiviewDFX.HiProfiler.HiDebug = true
    const.SystemCapability.HiviewDFX.HiSysEvent = true
    const.SystemCapability.Telephony.CallManager = true
    const.SystemCapability.Telephony.CoreService = true
    const.SystemCapability.Telephony.SmsMms = true
    const.SystemCapability.Telephony.CellularCall = true
    const.SystemCapability.Telephony.CellularData = true
    const.SystemCapability.Telephony.StateRegistry = true
    const.SystemCapability.Telephony.TelephonyEnhanced = true
    const.SystemCapability.Telephony.TelephonyEnhanced.VSim = true
    const.SystemCapability.Telephony.VoipCallManager = true
    const.SystemCapability.Multimedia.AVSession.AVCast = true
    const.SystemCapability.Multimedia.AVSession.Core = true
    const.SystemCapability.Multimedia.AVSession.ExtendedDisplayCast = true
    const.SystemCapability.Multimedia.AVSession.Manager = true
    const.SystemCapability.Multimedia.Audio.Capturer = true
    const.SystemCapability.Multimedia.Audio.Core = true
    const.SystemCapability.Multimedia.Audio.Tone = true
    const.SystemCapability.Multimedia.Audio.Device = true
    const.SystemCapability.Multimedia.Audio.Volume = true
    const.SystemCapability.Multimedia.Audio.Renderer = true
    const.SystemCapability.Multimedia.Audio.Communication = true
    const.SystemCapability.Multimedia.Audio.Interrupt = true
    const.SystemCapability.Multimedia.Audio.PlaybackCapture = true
    const.SystemCapability.Multimedia.Audio.Spatialization = true
    const.SystemCapability.Multimedia.Drm.Core = true
    const.SystemCapability.Multimedia.Image.Core = true
    const.SystemCapability.Multimedia.Image.ImageCreator = true
    const.SystemCapability.Multimedia.Image.ImagePacker = true
    const.SystemCapability.Multimedia.Image.ImageSource = true
    const.SystemCapability.Multimedia.Image.ImageReceiver = true
    const.SystemCapability.Multimedia.Media.AVImageGenerator = true
    const.SystemCapability.Multimedia.Media.AVPlayer = true
    const.SystemCapability.Multimedia.Media.Core = true
    const.SystemCapability.Multimedia.Media.Muxer = true
    const.SystemCapability.Multimedia.Media.Spliter = true
    const.SystemCapability.Multimedia.Media.AVRecorder = true
    const.SystemCapability.Multimedia.Media.AudioCodec = true
    const.SystemCapability.Multimedia.Media.CodecBase = true
    const.SystemCapability.Multimedia.Media.SoundPool = true
    const.SystemCapability.Multimedia.Media.AVScreenCapture = true
    const.SystemCapability.Multimedia.Media.AVTranscoder = true
    const.SystemCapability.Multimedia.Media.AudioDecoder = true
    const.SystemCapability.Multimedia.Media.AudioEncoder = true
    const.SystemCapability.Multimedia.Media.AudioPlayer = true
    const.SystemCapability.Multimedia.Media.VideoPlayer = true
    const.SystemCapability.Multimedia.Media.VideoDecoder = true
    const.SystemCapability.Multimedia.Media.VideoEncoder = true
    const.SystemCapability.Multimedia.Media.AudioRecorder = true
    const.SystemCapability.Multimedia.Media.VideoRecorder = true
    const.SystemCapability.Multimedia.Media.AVMetadataExtractor = true
    const.SystemCapability.Multimedia.Scan.Core = true
    const.SystemCapability.Multimedia.Scan.GenerateBarcode = true
    const.SystemCapability.Multimedia.Scan.ScanBarcode = true
    const.SystemCapability.Multimedia.Camera.Core = true
    const.SystemCapability.Multimedia.AudioHaptic.Core = true
    const.SystemCapability.Multimedia.ImageEffect.Core = true
    const.SystemCapability.Multimedia.ImageLoader.Core = true
    const.SystemCapability.Multimedia.SystemSound.Core = true
    const.SystemCapability.Multimedia.MediaLibrary.Core = true
    const.SystemCapability.Multimedia.MediaLibrary.DistributedCore = true
    const.SystemCapability.Multimedia.VideoProcessingEngine = true
    const.SystemCapability.GameService.GamePerformance = true
    const.SystemCapability.VirtService.Base = true
    const.SystemCapability.AppGalleryService.AppInfoManager = true
    const.SystemCapability.AppGalleryService.Distribution.OnDemandInstall = true
    const.SystemCapability.AppGalleryService.Distribution.Recommendations = true
    const.SystemCapability.AppGalleryService.Distribution.UnifiedInstall = true
    const.SystemCapability.AppGalleryService.Distribution.Update = true
    const.SystemCapability.AppGalleryService.PrivacyManager = true
    const.SystemCapability.AppGalleryService.AttributionManager = true
    const.SystemCapability.Applications.CalendarData = true
    const.SystemCapability.Applications.Contacts = true
    const.SystemCapability.Applications.Settings.Core = true
    const.SystemCapability.Applications.ContactsData = true
    const.SystemCapability.Developtools.Syscap = true
    const.SystemCapability.GraphicsGame.RenderAccelerate = true
    const.SystemCapability.MiscServices.Download = true
    const.SystemCapability.MiscServices.Theme = true
    const.SystemCapability.MiscServices.Time = true
    const.SystemCapability.MiscServices.Upload = true
    const.SystemCapability.MiscServices.InputMethodFramework = true
    const.SystemCapability.MiscServices.Pasteboard = true
    const.SystemCapability.MiscServices.ScreenLock = true
    const.SystemCapability.MiscServices.Wallpaper = true
    const.SystemCapability.Notification.CommonEvent = true
    const.SystemCapability.Notification.Emitter = true
    const.SystemCapability.Notification.Notification = true
    const.SystemCapability.Notification.NotificationSettings = true
    const.SystemCapability.Notification.ReminderAgent = true
    const.SystemCapability.PowerManager.BatteryManager.Core = true
    const.SystemCapability.PowerManager.BatteryManager.Extension = true
    const.SystemCapability.PowerManager.PowerManager.Core = true
    const.SystemCapability.PowerManager.PowerManager.Extension = true
    const.SystemCapability.PowerManager.ThermalManager = true
    const.SystemCapability.PowerManager.BatteryStatistics = true
    const.SystemCapability.PowerManager.DisplayPowerManager = true
    const.SystemCapability.PowerManager.DisplayPowerManager.Lite = true
    const.SystemCapability.BundleManager.AppDomainVerify = true
    const.SystemCapability.BundleManager.BundleFramework = true
    const.SystemCapability.BundleManager.BundleFramework.AppControl = true
    const.SystemCapability.BundleManager.BundleFramework.Core = true
    const.SystemCapability.BundleManager.BundleFramework.DefaultApp = true
    const.SystemCapability.BundleManager.BundleFramework.Launcher = true
    const.SystemCapability.BundleManager.BundleFramework.Overlay = true
    const.SystemCapability.BundleManager.BundleFramework.Resource = true
    const.SystemCapability.BundleManager.BundleFramework.FreeInstall = true
    const.SystemCapability.BundleManager.Zlib = true
    const.SystemCapability.BundleManager.DistributedBundleFramework = true
    const.SystemCapability.BundleManager.EcologicalRuleManager.EcologicalRuleDataManager = true
    const.SystemCapability.BundleManager.EcologicalRuleManager.SceneManager = true
    const.SystemCapability.Collaboration.Camera = true
    const.SystemCapability.Collaboration.DevicePicker = true
    const.SystemCapability.Collaboration.HarmonyShare = true
    const.SystemCapability.Collaboration.Service = true
    const.SystemCapability.Collaboration.SystemShare = true
    const.SystemCapability.Collaboration.NetworkSharing = true
    const.SystemCapability.Collaboration.ServiceManager = true
    const.SystemCapability.Collaboration.RemoteCommunication = true
    const.SystemCapability.Communication.Bluetooth.Core = true
    const.SystemCapability.Communication.Bluetooth.Lite = true
    const.SystemCapability.Communication.IPC.Core = true
    const.SystemCapability.Communication.NFC.CardEmulation = true
    const.SystemCapability.Communication.NFC.Core = true
    const.SystemCapability.Communication.NFC.Tag = true
    const.SystemCapability.Communication.NFC.WalletExt = true
    const.SystemCapability.Communication.NearLink.Core = true
    const.SystemCapability.Communication.NetStack = true
    const.SystemCapability.Communication.SoftBus.Core = true
    const.SystemCapability.Communication.WiFi.AP.Core = true
    const.SystemCapability.Communication.WiFi.Core = true
    const.SystemCapability.Communication.WiFi.P2P = true
    const.SystemCapability.Communication.WiFi.STA = true
    const.SystemCapability.Communication.NetManager.Core = true
    const.SystemCapability.Communication.NetManager.MDNS = true
    const.SystemCapability.Communication.NetManager.Vpn = true
    const.SystemCapability.Communication.NetManager.Ethernet = true
    const.SystemCapability.Communication.NetManager.NetFirewall = true
    const.SystemCapability.Communication.NetManager.NetSharing = true
    const.SystemCapability.Communication.NetManager.SmartHotSpot = true
    const.SystemCapability.Communication.NetworkBoost.Core = true
    const.SystemCapability.Communication.SecureElement = true
    const.SystemCapability.Customization.ConfigPolicy = true
    const.SystemCapability.Customization.CustomConfig = true
    const.SystemCapability.Customization.EnterpriseDeviceManager = true
    const.SystemCapability.Customization.EnterpriseDeviceManagerExt = true
    const.SystemCapability.OfficeService.PDFService.Core = true
    const.SystemCapability.WindowManager.WindowManager.Core = true
    const.SystemCapability.FileManagement.AppFileService = true
    const.SystemCapability.FileManagement.AppFileService.FolderAuthorization = true
    const.SystemCapability.FileManagement.File.DistributedFile = true
    const.SystemCapability.FileManagement.File.Environment = true
    const.SystemCapability.FileManagement.File.FileIO = true
    const.SystemCapability.FileManagement.File.FileIO.Lite = true
    const.SystemCapability.FileManagement.FilePreview.Core = true
    const.SystemCapability.FileManagement.StorageService.Backup = true
    const.SystemCapability.FileManagement.StorageService.Volume = true
    const.SystemCapability.FileManagement.StorageService.Encryption = true
    const.SystemCapability.FileManagement.StorageService.SpatialStatistics = true
    const.SystemCapability.FileManagement.DistributedFileService.CloudSync.Core = true
    const.SystemCapability.FileManagement.DistributedFileService.CloudSyncManager = true
    const.SystemCapability.FileManagement.PhotoAccessHelper.Core = true
    const.SystemCapability.FileManagement.UserFileManager.Core = true
    const.SystemCapability.FileManagement.UserFileManager.DistributedCore = true
    const.SystemCapability.FileManagement.UserFileService = true
    const.SystemCapability.MultimodalInput.Input.Cooperator = true
    const.SystemCapability.MultimodalInput.Input.Core = true
    const.SystemCapability.MultimodalInput.Input.Pointer = true
    const.SystemCapability.MultimodalInput.Input.ShortKey = true
    const.SystemCapability.MultimodalInput.Input.InfraredEmitter = true
    const.SystemCapability.MultimodalInput.Input.InputConsumer = true
    const.SystemCapability.MultimodalInput.Input.InputDevice = true
    const.SystemCapability.MultimodalInput.Input.InputMonitor = true
    const.SystemCapability.MultimodalInput.Input.InputSimulator = true
    const.SystemCapability.ResourceSchedule.BackgroundTaskManager.ContinuousTask = true
    const.SystemCapability.ResourceSchedule.BackgroundTaskManager.TransientTask = true
    const.SystemCapability.ResourceSchedule.BackgroundTaskManager.EfficiencyResourcesApply = true
    const.SystemCapability.ResourceSchedule.DeviceStandby = true
    const.SystemCapability.ResourceSchedule.SystemLoad = true
    const.SystemCapability.ResourceSchedule.WorkScheduler = true
    const.SystemCapability.ResourceSchedule.LowpowerManager = true
    const.SystemCapability.ResourceSchedule.UsageStatistics.App = true
    const.SystemCapability.ResourceSchedule.UsageStatistics.AppGroup = true
    const.SystemCapability.Resourceschedule.Ffrt.Core = true
    const.SystemCapability.AtomicserviceComponent.UIComponent = true
    const.SystemCapability.AtomicserviceComponent.atomicservice = true
    const.SystemCapability.AuthenticationServices.HuaweiID.Auth = true
    const.SystemCapability.AuthenticationServices.HuaweiID.ExtendService = true
    const.SystemCapability.AuthenticationServices.HuaweiID.MyFamily = true
    const.SystemCapability.AuthenticationServices.HuaweiID.RetailAuth = true
    const.SystemCapability.AuthenticationServices.HuaweiID.UIComponent = true
    const.SystemCapability.AuthenticationServices.HuaweiID.MinorsProtection = true
    const.SystemCapability.AuthenticationServices.HuaweiID.RealNameVerify = true
    const.SystemCapability.AuthenticationServices.HuaweiID.ShippingAddress = true
    const.SystemCapability.DeviceCloudGateway.ClientCloudCacheService.Grs = true
    const.SystemCapability.DeviceCloudGateway.CloudCapabilityManager = true
    const.SystemCapability.DeviceCloudGateway.CloudFoundation = true
    const.SystemCapability.UtilityApplication.ParentControl.Core = true
    const.SystemCapability.DistributedDataManager.CloudSync.Client = true
    const.SystemCapability.DistributedDataManager.CloudSync.Config = true
    const.SystemCapability.DistributedDataManager.CloudSync.Server = true
    const.SystemCapability.DistributedDataManager.DataShare.Consumer = true
    const.SystemCapability.DistributedDataManager.DataShare.Core = true
    const.SystemCapability.DistributedDataManager.DataShare.Provider = true
    const.SystemCapability.DistributedDataManager.KVStore.Core = true
    const.SystemCapability.DistributedDataManager.KVStore.DistributedKVStore = true
    const.SystemCapability.DistributedDataManager.UDMF.Core = true
    const.SystemCapability.DistributedDataManager.CommonType = true
    const.SystemCapability.DistributedDataManager.DataObject.DistributedObject = true
    const.SystemCapability.DistributedDataManager.Preferences.Core = true
    const.SystemCapability.DistributedDataManager.Preferences.Core.Lite = true
    const.SystemCapability.DistributedDataManager.RelationalStore.Core = true
    const.SystemCapability.DistributedHardware.DeviceManager = true
    const.SystemCapability.DistributedHardware.DistributedHardwareFWK = true
    const.SystemCapability.ScenarioFusionComponent.FileUriService = true
    ohos.boot.time.kernel = 2476032
    ohos.boot.time.init = 10569047
    ohos.boot.time.bms.main.bundles.ready = 17285693
    ohos.boot.time.wms.fullscreen.ready = 19769081
    ohos.boot.time.wms.ready = 19793538
    ohos.boot.time.samgr.ready = 10615671
    ohos.boot.time.boot.completed = 26583547
    ohos.boot.time.hdf_devmgr.ready = 10628298
    ohos.boot.time.appspawn.started = 10709817
    ohos.boot.time.useriam.fwkready = 13120256
    ohos.boot.time.appfwk.ready = 13464271
    ohos.boot.time.account.ready = 13500233
    ohos.boot.time.launcher.ready = 26583182
    ohos.boot.time.lockscreen.ready = 21863974
    ohos.boot.time.param_watcher.started = 10636987
    ohos.boot.time.renderservice.ready = 11336109
    ohos.boot.time.avsessionservice.ready = 12462154
    ohos.boot.time.bootanimation.ready = 12884752
    ohos.boot.time.bootanimation.started = 13143584
    ohos.boot.time.bootanimation.finished = 21261009
    bootevent.boot.completed = true
    persist.sys.hilog.kmsg.on = true
    persist.sys.hilog.binary.on = true
    persist.sys.hilog.binary.forhota.on = false
    hilog.flowctrl.proc.on = true
    hilog.flowctrl.domain.on = true
    hilog.level.debug.on = false
    hilog.loggable.global = I
    hilog.buffersize.global = 262144
    const.hdc.version = Ver: 3.0.0b
    web.debug.devtools = false
    web.debug.netlog = None
    web.debug.trace = false
    web.debug.strictsiteIsolation.enable = none
    persist.hdc.jdwp = 0
    persist.time.auto_restore_timer_apps = com.huawei.hmos.clock,com.huawei.hmos.settings,com.huawei.hmos.emergencycommunication
    persist.time.ntpserver = 1.cn.pool.ntp.org,ntp.sjtu.edu.cn,time.windows.com,time.nist.gov,pool.ntp.org
    persist.time.timezone = Asia/Shanghai
    persist.time.ntpserver_specific =
    persist.time.auto_time = ON
    persist.global.tz_override = false
    const.product.devicetype = phone
    const.build.characteristics = default 

设备基本信息

字段名称含义
const.product.productid产品的唯一标识符。
const.product.model设备型号(例如 ALN-AL00 表示 HUAWEI Mate 60 Pro 的具体型号)。
const.product.name设备名称。
const.product.brand品牌名称,例如 HUAWEI。
const.product.manufacturer设备制造商名称,例如 HUAWEI。
const.product.devicetype设备类型,例如 phone 表示手机。
const.product.hardwareversion硬件版本号(例如 HL1CMSM)。
const.product.cpu.abilist支持的 CPU 架构,例如 arm64-v8a 表示 64 位 ARM 架构。
const.product.device_radius设备的物理尺寸或显示尺寸。

操作系统信息

字段名称含义
const.product.os.dist.apiname操作系统 API 名称,例如 OpenHarmony 的版本号。
const.product.os.dist.version操作系统版本号。
const.product.os.dist.apiversion操作系统的 API 版本号,例如 50001 表示 OpenHarmony 的版本级别。
const.product.os.dist.releasetype操作系统的发布类型(如 Release 表示稳定版本)。
const.ohos.version.security_patch操作系统的安全补丁日期。
const.ohos.version.certified系统认证的版本号,例如 OpenHarmony 5.0.1。
const.ohos.apiversionHarmonyOS 的 API 版本号,例如 13
const.ohos.fullname完整的系统版本名称,例如 OpenHarmony-5.0.1.120。

构建与发布信息

字段名称含义
const.build.description构建描述,包括版本号和签名类型。
const.build.product产品代号,例如 ALN。
const.build.vendor.date供应商构建日期(精确到秒)。
const.build.system.date系统构建日期(精确到秒)。
const.build.sa_sdk_version使用的 SDK 版本号。
const.product.build.type构建类型(如 default 表示默认构建)。
const.product.build.user构建用户(通常为 default)。
const.product.build.host构建主机名(通常为 default)。
const.product.software.version软件的完整版本号,包括区域和构建版本信息。

系统功能支持(SystemCapability)

这些字段定义了系统支持的能力模块,每个字段以布尔值表示是否支持。以下是常见字段示例:

人工智能相关
字段名称含义
const.SystemCapability.AI.AICaption支持 AI 图像字幕生成。
const.SystemCapability.AI.TextToSpeech支持文本转语音功能。
const.SystemCapability.AI.Vision.ObjectDetection支持 AI 图像物体检测。
const.SystemCapability.AI.Face.Detector支持人脸检测功能。
系统能力模块
字段名称含义
const.SystemCapability.Ability.AbilityBase支持基本的系统能力。
const.SystemCapability.BundleManager.BundleFramework支持应用管理框架。
const.SystemCapability.Notification.Notification支持通知功能模块。
const.SystemCapability.Location.Location.Core支持位置服务的核心功能。
多媒体功能
字段名称含义
const.SystemCapability.Multimedia.Audio.Core支持音频处理的核心功能。
const.SystemCapability.Multimedia.Media.AVPlayer支持音视频播放器功能。
const.SystemCapability.Multimedia.Camera.Core支持摄像头功能的核心模块。

启动时间与性能信息

字段名称含义
ohos.boot.time.kernel内核启动时间(毫秒)。
ohos.boot.time.init系统初始化完成时间(毫秒)。
ohos.boot.time.wms.ready窗口管理服务准备好的时间点。
ohos.boot.time.launcher.ready桌面启动器准备好的时间点。
bootevent.boot.completed系统启动是否完成(布尔值)。

持久化配置

字段名称含义
persist.sys.hilog.kmsg.on是否启用系统日志记录。
persist.time.ntpserverNTP 时间同步服务器列表。
persist.time.auto_time是否自动更新时间(如 ON 表示启用)。
persist.global.tz_override是否覆盖默认时区设置(布尔值)。

8 获取指定应用的名称,先将后台应用全退,再运行要查看的应用,

 aa dump -l

 得到如果,就是上划进入任务管理器中任务的列表

User ID #100
  current mission lists:{
    Mission ID #68  mission name #[#com.tencent.mqq:entry:EntryAbility]  lockedState #0  mission affinity #[]
      AbilityRecord ID #701
        app name [com.tencent.mqq]
        main name [EntryAbility]
        bundle name [com.tencent.mqq]
        ability type [PAGE]
        state #BACKGROUND  start time [69617025]
        app state #BACKGROUND
        ready #1  window attached #0  launcher #0
        callee connections:
        isKeepAlive: false
 }
    Mission ID #109  mission name #[#com.xingin.xhs_hos:redbook:EntryAbility]  lockedState #0  mission affinity #[]
      AbilityRecord ID #1675
        app name [com.xingin.xhs_hos]
        main name [EntryAbility]
        bundle name [com.xingin.xhs_hos]
        ability type [PAGE]
        state #BACKGROUND  start time [221407252]
        app state #BACKGROUND
        ready #1  window attached #0  launcher #0
        callee connections:
        isKeepAlive: false
 }
    Mission ID #111  mission name #[#com.tencent.wechat:entry:EntryAbility]  lockedState #0  mission affinity #[]
      AbilityRecord ID #1677
        app name [com.tencent.wechat]
        main name [EntryAbility]
        bundle name [com.tencent.wechat]
        ability type [PAGE]
        state #BACKGROUND  start time [221410026]
        app state #BACKGROUND
        ready #1  window attached #0  launcher #0
        callee connections:
        isKeepAlive: false
 }

9获取界面的结构图

hdc shell uitest dumpLayout

hdc file recv /data/local/tmp/xxxx.json

 10模拟点击(输入文字)等

操作类型必选参数可选参数示例
单击point_x, point_yhdc shell uitest uiInput click 100 100
双击point_x, point_yhdc shell uitest uiInput doubleClick 100 100
长按point_x, point_yhdc shell uitest uiInput longClick 100 100
快滑from_x, from_y, to_x, to_yswipeVelocityPps_ (默认 600), stepLengthhdc shell uitest uiInput fling 10 10 200 200 500
慢滑from_x, from_y, to_x, to_yswipeVelocityPps_ (默认 600)hdc shell uitest uiInput swipe 10 10 200 200 500
拖拽from_x, from_y, to_x, to_yswipeVelocityPps_ (默认 600)hdc shell uitest uiInput drag 10 10 100 100 500
指定方向滑动direction (0: 左, 1: 右, 2: 上, 3: 下), swipeVelocityPps_, stepLengthhdc shell uitest uiInput dircFling 0 500
输入框输入point_x, point_y, inputhdc shell uitest uiInput inputText 100 100 "hello 中国人"
实体按键事件keyIDkeyID2hdc shell uitest uiInput keyEvent Home
组合按键事件keyID, keyID2hdc shell uitest uiInput keyEvent 2072 2038

键盘映射表如下: 


NameValueDescription
KEYCODE_FN0Function (Fn) key
KEYCODE_UNKNOWN-1Unknown key
KEYCODE_HOME1Function (Home) key
KEYCODE_BACK2Back key
KEYCODE_MEDIA_PLAY_PAUSE10Play/Pause key
KEYCODE_MEDIA_STOP11Stop key
KEYCODE_MEDIA_NEXT12Next key
KEYCODE_MEDIA_PREVIOUS13Previous key
KEYCODE_MEDIA_REWIND14Rewind key
KEYCODE_MEDIA_FAST_FORWARD15Fast Forward key
KEYCODE_VOLUME_UP16Volume Up key
KEYCODE_VOLUME_DOWN17Volume Down key
KEYCODE_POWER18Power key
KEYCODE_CAMERA19Camera key
KEYCODE_VOLUME_MUTE22Speaker Mute key
KEYCODE_MUTE23Mute key
KEYCODE_BRIGHTNESS_UP40Brightness Up key
KEYCODE_BRIGHTNESS_DOWN41Brightness Down key
KEYCODE_02000Key 0
KEYCODE_12001Key 1
KEYCODE_22002Key 2
KEYCODE_32003Key 3
KEYCODE_42004Key 4
KEYCODE_52005Key 5
KEYCODE_62006Key 6
KEYCODE_72007Key 7
KEYCODE_82008Key 8
KEYCODE_92009Key 9
KEYCODE_STAR2010Key *
KEYCODE_POUND2011Key #
KEYCODE_DPAD_UP2012Up key on D-pad
KEYCODE_DPAD_DOWN2013Down key on D-pad
KEYCODE_DPAD_LEFT2014Left key on D-pad
KEYCODE_DPAD_RIGHT2015Right key on D-pad
KEYCODE_DPAD_CENTER2016Center key on D-pad
KEYCODE_A2017Key A
KEYCODE_B2018Key B
KEYCODE_C2019Key C
KEYCODE_D2020Key D
KEYCODE_E2021Key E
KEYCODE_F2022Key F
KEYCODE_G2023Key G
KEYCODE_H2024Key H
KEYCODE_I2025Key I
KEYCODE_J2026Key J
KEYCODE_K2027Key K
KEYCODE_L2028Key L
KEYCODE_M2029Key M
KEYCODE_N2030Key N
KEYCODE_O2031Key O
KEYCODE_P2032Key P
KEYCODE_Q2033Key Q
KEYCODE_R2034Key R
KEYCODE_S2035Key S
KEYCODE_T2036Key T
KEYCODE_U2037Key U
KEYCODE_V2038Key V
KEYCODE_W2039Key W
KEYCODE_X2040Key X
KEYCODE_Y2041Key Y
KEYCODE_Z2042Key Z
KEYCODE_COMMA2043Key ,
KEYCODE_PERIOD2044Key .
KEYCODE_ALT_LEFT2045Left Alt key
KEYCODE_ALT_RIGHT2046Right Alt key
KEYCODE_SHIFT_LEFT2047Left Shift key
KEYCODE_SHIFT_RIGHT2048Right Shift key
KEYCODE_TAB2049Tab key
KEYCODE_SPACE2050Space key
KEYCODE_SYM2051Symbol key
KEYCODE_EXPLORER2052Explorer key, used to start the explorer application
KEYCODE_ENVELOPE2053Email key, used to start the email application
KEYCODE_ENTER2054Enter key
KEYCODE_DEL2055Delete key
KEYCODE_GRAVE2056Key `
KEYCODE_MINUS2057Key -
KEYCODE_EQUALS2058Key =
KEYCODE_LEFT_BRACKET2059Key [
KEYCODE_RIGHT_BRACKET2060Key ]
KEYCODE_BACKSLASH2061Key \
KEYCODE_SEMICOLON2062Key ;
KEYCODE_APOSTROPHE2063Key ’
KEYCODE_SLASH2064Key /
KEYCODE_AT2065Key @
KEYCODE_PLUS2066Key +
KEYCODE_MENU2067Menu key
KEYCODE_PAGE_UP2068Page Up key
KEYCODE_PAGE_DOWN2069Page Down key
KEYCODE_ESCAPE2070ESC key
KEYCODE_FORWARD_DEL2071Delete key
KEYCODE_CTRL_LEFT2072Left Ctrl key
KEYCODE_CTRL_RIGHT2073Right Ctrl key
KEYCODE_CAPS_LOCK2074Caps Lock key
KEYCODE_SCROLL_LOCK2075Scroll Lock key
KEYCODE_META_LEFT2076Left Meta key
KEYCODE_META_RIGHT2077Right Meta key
KEYCODE_FUNCTION2078Function key
KEYCODE_SYSRQ2079System Request/Print Screen key
KEYCODE_BREAK2080Break/Pause key
KEYCODE_MOVE_HOME2081Move to Home key
KEYCODE_MOVE_END2082Move to End key
KEYCODE_INSERT2083Insert key
KEYCODE_FORWARD2084Forward key
KEYCODE_MEDIA_PLAY2085Play key
KEYCODE_MEDIA_PAUSE2086Pause key
KEYCODE_MEDIA_CLOSE2087Close key
KEYCODE_MEDIA_EJECT2088Eject key
KEYCODE_MEDIA_RECORD2089Record key
KEYCODE_F12090F1 key
KEYCODE_F22091F2 key
KEYCODE_F32092F3 key
KEYCODE_F42093F4 key
KEYCODE_F52094F5 key
KEYCODE_F62095F6 key
KEYCODE_F72096F7 key
KEYCODE_F82097F8 key
KEYCODE_F92098F9 key
KEYCODE_F102099F10 key
KEYCODE_F112100F11 key
KEYCODE_F122101F12 key
KEYCODE_NUM_LOCK2102Number Lock key
KEYCODE_NUMPAD_02103Key 0 on numeric keypad
KEYCODE_NUMPAD_12104Key 1 on numeric keypad
KEYCODE_NUMPAD_22105Key 2 on numeric keypad
KEYCODE_NUMPAD_32106Key 3 on numeric keypad
KEYCODE_NUMPAD_42107Key 4 on numeric keypad
KEYCODE_NUMPAD_52108Key 5 on numeric keypad
KEYCODE_NUMPAD_62109Key 6 on numeric keypad
KEYCODE_NUMPAD_72110Key 7 on numeric keypad
KEYCODE_NUMPAD_82111Key 8 on numeric keypad
KEYCODE_NUMPAD_92112Key 9 on numeric keypad
KEYCODE_NUMPAD_DIVIDE2113Key / on numeric keypad
KEYCODE_NUMPAD_MULTIPLY2114Key * on numeric keypad
KEYCODE_NUMPAD_SUBTRACT2115Key - on numeric keypad
KEYCODE_NUMPAD_ADD2116Key + on numeric keypad
KEYCODE_NUMPAD_DOT2117Key . on numeric keypad
KEYCODE_NUMPAD_COMMA2118Key , on numeric keypad
KEYCODE_NUMPAD_ENTER2119Enter key on numeric keypad
KEYCODE_NUMPAD_EQUALS2120Key = on numeric keypad
KEYCODE_NUMPAD_LEFT_PAREN2121Key ( on numeric keypad
KEYCODE_NUMPAD_RIGHT_PAREN2122Key ) on numeric keypad
KEYCODE_VIRTUAL_MULTITASK2210Multi-task key
KEYCODE_SLEEP2600Sleep key
KEYCODE_ZENKAKU_HANKAKU2601Zenkaku/Hankaku key
KEYCODE_102ND2602102nd key
KEYCODE_RO2603Ro key
KEYCODE_KATAKANA2604Katakana key
KEYCODE_HIRAGANA2605Hiragana key
KEYCODE_HENKAN2606Henkan key
KEYCODE_KATAKANA_HIRAGANA2607Katakana/Hiragana key
KEYCODE_MUHENKAN2608Muhenkan key
KEYCODE_LINEFEED2609Linefeed key
KEYCODE_MACRO2610Macro key
KEYCODE_NUMPAD_PLUSMINUS2611Plus/Minus key on the numeric keypad
KEYCODE_SCALE2612Scale key
KEYCODE_HANGUEL2613Hanguel key
KEYCODE_HANJA2614Hanja key
KEYCODE_YEN2615Yen key
KEYCODE_STOP2616Stop key
KEYCODE_AGAIN2617Again key
KEYCODE_PROPS2618Props key
KEYCODE_UNDO2619Undo key
KEYCODE_COPY2620Copy key
KEYCODE_OPEN2621Open key
KEYCODE_PASTE2622Paste key
KEYCODE_FIND2623Find key
KEYCODE_CUT2624Cut key
KEYCODE_HELP2625Help key
KEYCODE_CALC2626Calc key, used to start the calculator application
KEYCODE_FILE2627File key
KEYCODE_BOOKMARKS2628Bookmarks key
KEYCODE_NEXT2629Next key
KEYCODE_PLAYPAUSE2630Play/Pause key
KEYCODE_PREVIOUS2631Previous key
KEYCODE_STOPCD2632Stop CD key
KEYCODE_CONFIG2634Config key
KEYCODE_REFRESH2635Refresh key
KEYCODE_EXIT2636Exit key
KEYCODE_EDIT2637Edit key
KEYCODE_SCROLLUP2638Scroll Up key
KEYCODE_SCROLLDOWN2639Scroll Down key
KEYCODE_NEW2640New key
KEYCODE_REDO2641Redo key
KEYCODE_CLOSE2642Close key
KEYCODE_PLAY2643Play key
KEYCODE_BASSBOOST2644Bass Boost key
KEYCODE_PRINT2645Print key
KEYCODE_CHAT2646Chat key
KEYCODE_FINANCE2647Finance key
KEYCODE_CANCEL2648Cancel key
KEYCODE_KBDILLUM_TOGGLE2649Keyboard Illumination Toggle key
KEYCODE_KBDILLUM_DOWN2650Keyboard Illumination Up key
KEYCODE_KBDILLUM_UP2651Keyboard Illumination Down key
KEYCODE_SEND2652Send key
KEYCODE_REPLY2653Reply key
KEYCODE_FORWARDMAIL2654Forward Mail key
KEYCODE_SAVE2655Save key
KEYCODE_DOCUMENTS2656Documents key
KEYCODE_VIDEO_NEXT2657Next Video key
KEYCODE_VIDEO_PREV2658Previous Video key
KEYCODE_BRIGHTNESS_CYCLE2659Brightness Cycle key
KEYCODE_BRIGHTNESS_ZERO2660Brightness Zero key
KEYCODE_DISPLAY_OFF2661Display Off Key
KEYCODE_BTN_MISC2662Misc Button key
KEYCODE_GOTO2663Goto key
KEYCODE_INFO2664Info key
KEYCODE_PROGRAM2665Program key
KEYCODE_PVR2666PVR key
KEYCODE_SUBTITLE2667Subtitle key
KEYCODE_FULL_SCREEN2668Full Screen key
KEYCODE_KEYBOARD2669Keyboard
KEYCODE_ASPECT_RATIO2670Aspect Ratio key
KEYCODE_PC2671Port Control key
KEYCODE_TV2672TV key
KEYCODE_TV22673TV key 2
KEYCODE_VCR2674VCR key
KEYCODE_VCR22675VCR key 2
KEYCODE_SAT2676SAT key
KEYCODE_CD2677CD key
KEYCODE_TAPE2678Tape key
KEYCODE_TUNER2679Tuner key
KEYCODE_PLAYER2680Player key
KEYCODE_DVD2681DVD key
KEYCODE_AUDIO2682Audio key
KEYCODE_VIDEO2683Video key
KEYCODE_MEMO2684Memo key
KEYCODE_CALENDAR2685Calendar key
KEYCODE_RED2686Red indicator
KEYCODE_GREEN2687Green indicator
KEYCODE_YELLOW2688Yellow indicator
KEYCODE_BLUE2689Blue indicator
KEYCODE_CHANNELUP2690Channel Up key
KEYCODE_CHANNELDOWN2691Channel Down key
KEYCODE_LAST2692Last key
KEYCODE_RESTART2693Restart key
KEYCODE_SLOW2694Slow key
KEYCODE_SHUFFLE2695Shuffle key
KEYCODE_VIDEOPHONE2696Videophone key
KEYCODE_GAMES2697Games key
KEYCODE_ZOOMIN2698Zoom-in key
KEYCODE_ZOOMOUT2699Zoom-out key
KEYCODE_ZOOMRESET2700Zoom Reset key
KEYCODE_WORDPROCESSOR2701Word Processor key
KEYCODE_EDITOR2702Editor key
KEYCODE_SPREADSHEET2703Spreadsheet key
KEYCODE_GRAPHICSEDITOR2704Graphics Editor key
KEYCODE_PRESENTATION2705Presentation key
KEYCODE_DATABASE2706Database key
KEYCODE_NEWS2707News key
KEYCODE_VOICEMAIL2708Voicemail key
KEYCODE_ADDRESSBOOK2709Addressbook key
KEYCODE_MESSENGER2710Messenger key
KEYCODE_BRIGHTNESS_TOGGLE2711Brightness Toggle key
KEYCODE_SPELLCHECK2712Spell Check key
KEYCODE_COFFEE2713Coffee key, used to launch screen lock or screen saver
KEYCODE_MEDIA_REPEAT2714Media Repeat key
KEYCODE_IMAGES2715Images key
KEYCODE_BUTTONCONFIG2716Button Configuration key
KEYCODE_TASKMANAGER2717Task Manager key
KEYCODE_JOURNAL2718Log key
KEYCODE_CONTROLPANEL2719Control Panel key
KEYCODE_APPSELECT2720App Select key
KEYCODE_SCREENSAVER2721Screen Saver key
KEYCODE_ASSISTANT2722Assistant key
KEYCODE_KBD_LAYOUT_NEXT2723Next Keyboard Layout key
KEYCODE_BRIGHTNESS_MIN2724Min Brightness key
KEYCODE_BRIGHTNESS_MAX2725Max Brightness key
KEYCODE_KBDINPUTASSIST_PREV2726Assist_Previous key, used to view historical inputs.
KEYCODE_KBDINPUTASSIST_NEXT2727Assist_Next key, used to view predictive inputs.
KEYCODE_KBDINPUTASSIST_PREVGROUP2728Assist_Previous_Group key, used to switch to the previous input method in the input group.
KEYCODE_KBDINPUTASSIST_NEXTGROUP2729Assist_Next_Group key, used to switch to the next input method in the input group.
KEYCODE_KBDINPUTASSIST_ACCEPT2730Keyboard Input-assisted Accept key
KEYCODE_KBDINPUTASSIST_CANCEL2731Keyboard Input-assisted Cancel key
KEYCODE_FRONT2800Front key, used to launch the windshield defogger
KEYCODE_SETUP2801Setup key
KEYCODE_WAKEUP2802Wakeup key
KEYCODE_SENDFILE2803Send File key
KEYCODE_DELETEFILE2804Delete File key
KEYCODE_XFER2805XFER key, used to start file transfer
KEYCODE_PROG12806Program key 1
KEYCODE_PROG22807Program key 2
KEYCODE_MSDOS2808MS-DOS key
KEYCODE_SCREENLOCK2809Screen Lock key
KEYCODE_DIRECTION_ROTATE_DISPLAY2810Directional Rotation Display key
KEYCODE_CYCLEWINDOWS2811Windows Cycle key
KEYCODE_COMPUTER2812Keys
KEYCODE_EJECTCLOSECD2813Eject CD key
KEYCODE_ISO2814ISO key
KEYCODE_MOVE2815Move key
KEYCODE_F132816F13 key
KEYCODE_F142817F14 key
KEYCODE_F152818F15 key
KEYCODE_F162819F16 key
KEYCODE_F172820F17 key
KEYCODE_F182821F18 key
KEYCODE_F192822F19 key
KEYCODE_F202823F20 key
KEYCODE_F212824F21 key
KEYCODE_F222825F22 key
KEYCODE_F232826F23 key
KEYCODE_F242827F24 key
KEYCODE_PROG32828Program key 3
KEYCODE_PROG42829Program key 4
KEYCODE_DASHBOARD2830Dashboard
KEYCODE_SUSPEND2831Suspend key
KEYCODE_HP2832HP key
KEYCODE_SOUND2833Sound key
KEYCODE_QUESTION2834Question key
KEYCODE_CONNECT2836Connect key
KEYCODE_SPORT2837Sport key
KEYCODE_SHOP2838Shop key
KEYCODE_ALTERASE2839Alternate key
KEYCODE_SWITCHVIDEOMODE2841Switch Video Mode key (monitor, LCD, and TV, etc.)
KEYCODE_BATTERY2842Battery key
KEYCODE_BLUETOOTH2843Bluetooth key
KEYCODE_WLAN2844WLAN key
KEYCODE_UWB2845Ultra-wideband key
KEYCODE_WWAN_WIMAX2846WWAN WiMAX key
KEYCODE_RFKILL2847RF Kill key
KEYCODE_CHANNEL3001Channel key
KEYCODE_BTN_03100Button 0
KEYCODE_BTN_13101Button 1
KEYCODE_BTN_23102Button 2
KEYCODE_BTN_33103Button 3
KEYCODE_BTN_43104Button 4
KEYCODE_BTN_53105Button 5
KEYCODE_BTN_63106Button 6
KEYCODE_BTN_73107Button 7
KEYCODE_BTN_83108Button 8
KEYCODE_BTN_93109Button 9

 

 其它常用指令(未整理)

1、hdc是否安装成功
命令:hdc shell (能识别即成功)
2、关机
命令:hdc shell reboot shutdown
3、、重新启动系统
命令:hdc shell reboot
4、安装应用:
命令:hdc install 应用包所在路径
举例:hdc install D:\browser.hap
5、卸载应用
命令:hdc uninstall [BundleName]
举例:hdc uninstall com.archermind.web
6、查BundleName和AbilityName名称
命令:hdc shell wukong appinfo
7、上传文件到pad
命令:hdc file send 文件路径(文件位置) 文件上传pad的路径
举例:hdc file send D:\8.jpg /data/local/tmp
8、从pad下载文件到电脑
命令:hdc file recv 文件路径(文件位置) 文件下载到电脑的路径
举例:hdc file recv /data/local/tmp/aa.jpeg D:\
9、查看日志
命令:hdc hilog
10、抓取log并保存
命令:hdc hilog >log.log
举例:hdc hilog > D:\log.txt
11、查询连接设备
命令:hdc list targets
12、获取设备udid
命令:hdc shell bm get -u
13、查看应用配置信息
命令:hdc shell bm dump -n [BundleName]
举例:hdc shell bm dump -n com.tencent.wechat
14、清除应用缓存
命令:hdc shell bm clean -n [BundleName] -c
举例:hdc shell bm clean -n com.archermind.web -c
15、清除应用数据
命令:hdc shell bm clean -n [BundleName] -d
举例:hdc shell bm clean -n com.archermind.web -d
16、启动指定应用
命令:hdc shell aa start -a EntryAbility -b 包名
举例: hdc shell aa start -a EntryAbility -b com.archermind.web
17、强制退出应用
命令:hdc shell aa force-stop [BundleName]
举例:hdc shell aa force-stop com.superred.reminder
18、查看当前任务栈的ability信息(后台启动的应用)
命令:hdc shell aa dump -l
19、截图
命令:
hdc shell snapshot_display -f /data/local/tmp/screenshot.jpeg
hdc shell file recv/data/local/tmp/screenshot.jpeg  D:
20、获取进程信息和线程信息
hdc shell top
21、查看屏幕信息
hdc shell hidumper -s 10 -a screen
22、查看当前窗口信息
hdc shell hidumper -s WindowManagerService -a ‘-a’
23、获取应用信息
hdc shell aa dump -a


http://www.kler.cn/a/506149.html

相关文章:

  • 大文件上传的解决办法~文件切片、秒传、限制文件并发请求。。。
  • 网管平台(进阶篇):路由器的管理实践
  • 从漏洞管理到暴露管理:网络安全的新方向
  • linux之进程信号(初识信号,信号的产生)
  • vue项目引入阿里云svg资源图标
  • React第二十二章(useDebugValue)
  • 判断192.168.1.0/24网络中,当前在线的ip有哪些
  • 文件上传生成pdf
  • 混币器是什么,波卡跨链交易平台
  • 河道流量在线自动监测系统:实时监控水流,保障河道管理安全
  • 阿里云轻量应用服务器全新升级,通用型实例峰值带宽高达200Mbps
  • 基于Oracle与PyQt6的电子病历多模态大模型图形化查询系统编程构建
  • 使用Go语言中的Buffer实现高性能处理字节和字符串
  • hashcat破解密码时出现signature unmatched error或者no hashes loaded的一种可能的原因
  • IP归属地为什么和定位不一致?原因解析
  • linux入门一
  • tomcat状态一直是Exited (1)
  • 【一个按钮一个LED】用STM32F030单片机实现苹果充电器的定时装置
  • Coconut:基于连续潜在空间推理,提升大语言模型推理能力的新方法
  • Dataset之COCO数据集:COCO数据集
  • jenkins-node节点配置
  • vue3+elementPlus之后台管理系统(从0到1)(day1)
  • leetcode:205. 同构字符串(python3解法)
  • Scala语言的多线程编程
  • 洛谷题目:P1025 [NOIP2001 提高组] 数的划分 题解
  • 剑指Offer 砍竹子