openharmony 鸿蒙 js-apidiff-usb

2023-02-03 浏览 (644)

JS API Changes of the USB Subsystem

The table below lists the APIs changes of the USB subsystem in OpenHarmony 3.2 Beta2 over OpenHarmony 3.2 Beta1.

API Changes

ModuleClassMethod/Attribute/Enumeration/ConstantChange Type
ohos.usbFunctionTypeNCM = 256Added
ohos.usbFunctionTypeAUDIO_SOURCE = 128Added
ohos.usbFunctionTypeMIDI = 64Added
ohos.usbFunctionTypeRNDIS = 32Added
ohos.usbFunctionTypePTP = 16Added
ohos.usbFunctionTypeMTP = 8Added
ohos.usbFunctionTypeHDC = 4Added
ohos.usbFunctionTypeECM = 2Added
ohos.usbFunctionTypeACM = 1Added
ohos.usbFunctionTypeNONE = 0Added
ohos.usbUSBPortstatus: USBPortStatus;Added
ohos.usbUSBPortsupportedModes: PortModeType;Added
ohos.usbUSBPortid: number;Added
ohos.usbUSBPortStatuscurrentDataRole: number;Added
ohos.usbUSBPortStatuscurrentPowerRole: number;Added
ohos.usbUSBPortStatuscurrentMode: number;Added
ohos.usbPortModeTypeNUM_MODES = 4Added
ohos.usbPortModeTypeDRP = 3Added
ohos.usbPortModeTypeDFP = 2Added
ohos.usbPortModeTypeUFP = 1Added
ohos.usbPortModeTypeNONE = 0Added
ohos.usbDataRoleTypeDEVICE = 2Added
ohos.usbDataRoleTypeHOST = 1Added
ohos.usbDataRoleTypeNONE = 0Added
ohos.usbPowerRoleTypeSINK = 2Added
ohos.usbPowerRoleTypeSOURCE = 1Added
ohos.usbPowerRoleTypeNONE = 0Added
ohos.usbusbsetPortRoles(portId: number, powerRole: PowerRoleType, dataRole: DataRoleType): Promise<boolean>;Added
ohos.usbusbgetSupportedModes(portId: number): PortModeType;Added
ohos.usbusbgetPorts(): Array<USBPort>;Added
ohos.usbusbgetCurrentFunctions(): FunctionType;Added
ohos.usbusbsetCurrentFunctions(funcs: FunctionType): Promise<boolean>;Added
ohos.usbusbusbFunctionsToString(funcs: FunctionType): string;Added
ohos.usbusbusbFunctionsFromString(funcs: string): number;Added

你可能感兴趣的鸿蒙文章

harmony 鸿蒙JS API Changes of the Ability Framework

harmony 鸿蒙JS API Changes of the Accessibility Subsystem

harmony 鸿蒙JS API Changes of the Account Subsystem

harmony 鸿蒙JS API Changes of the ArkUI Development Framework

harmony 鸿蒙JS API Changes of the Bundle Management Framework

harmony 鸿蒙JS API Changes of the Communication Subsystem

harmony 鸿蒙JS API Changes of the Compiler and Runtime Subsystem

harmony 鸿蒙JS API Changes of the DFX Subsystem

harmony 鸿蒙JS API Changes of the Distributed Data Management Subsystem

harmony 鸿蒙JS API Changes of the Common Event and Notification Subsystem

  • 所属分类: 后端技术
  • 本文标签: 鸿蒙 软件
  • 版权声明: 本文链接 https://seaxiang.com/blog/e9671d603fd24786b7f49a65d9114cde