文件最后提交记录最后更新时间
!982 适配991,image规避文件沙箱对文件命名作出限制 * update picture * update 991 and bugfix image 3 年前
!883 README 整改 * README整改 * README整改 * README整改 3 年前
!854 【OpenHarmony开源贡献者计划2022】【中文翻译】issues/I5CXU8翻译任务&readme更新 * Signed-off-by: Theodore C <ccooperr@protonmail.com> * Signed-off-by: Theodore C <ccooperr@protonmail.com> 3 年前
!1129 README 增加Full SDK说明,增加USB监听说明 * update README_zh.md 3 年前
!813 【OpenHarmony】新增USB管理 * 新增USB管理 3 年前
!813 【OpenHarmony】新增USB管理 * 新增USB管理 3 年前
!982 适配991,image规避文件沙箱对文件命名作出限制 * update picture * update 991 and bugfix image 3 年前
README.md

USB management

Introduction

This example demonstrates the use of USB device management, including USB device insertion and removal status monitoring and USB device information display. The results are as follows:

Related Conceptions

  1. Subscribe to USB Listening Events : Obtain the interface usage status by subscribing to the USB insertion and removal listening events.

  2. Get USB Device List: Gets the list of plugged in USB devices.

Not involved

Usage

  1. Open the USB Listening switch, and the interface pops up the prompt of "Start Listening...".

  2. Plug in the device, the interface will have a "USB plugged in" prompt, the device list will show the plugged in device. If the list is not updated in time, you can manually refresh the drop-down list.

  3. Click on the device, the pop-up box will display the specific information of the USB device, click the OK button to return to the main page.

  4. Unplug the USB device, the interface will have a "removed device" prompt, and the device list will remove the device model. If the list is not updated in time, you can manually refresh the drop-down list.

Constraints and Restrictions

  1. This example is only supported to run on standard systems.

  2. This example needs to use DevEco Studio version 3.0.0.901 and above to compile and run.