openharmony 鸿蒙 capi-usb-serial-types-h

2026-08-25 浏览 (1)

usb_serial_types.h

Overview

Provides the enum variables, structures, and macros used in USB Serial DDK APIs.

File to include: <usb_serial/usb_serial_types.h>

Library: libusb_serial_ndk.z.so

System capability: SystemCapability.Driver.UsbSerial.Extension

Since: 18

Related module: USBSerialDDK

Summary

Structs

Nametypedef KeywordDescription
UsbSerial_Params__attribute__((aligned(8))) UsbSerial_ParamsDefines the USB serial port parameters for the USB Serial DDK.
UsbSerial_DeviceUsbSerial_DeviceDefines the data structures for the USB serial port device (opaque).

Enums

Nametypedef KeywordDescription
UsbSerial_DdkRetCodeUsbSerial_DdkRetCodeDefines the return codes used by the USB Serial DDK.
UsbSerial_FlowControlUsbSerial_FlowControlDefines the flow control mode for the USB Serial DDK.
UsbSerial_ParityUsbSerial_ParityDefines the enums of the parity parameter used by the USB Serial DDK.

Enum Description

UsbSerial_DdkRetCode

enum UsbSerial_DdkRetCode

Description

Defines the return codes used by the USB Serial DDK.

Since: 18

EnumDescription
USB_SERIAL_DDK_NO_PERM = 201No access permission.
USB_SERIAL_DDK_INVALID_PARAMETER = 401Invalid parameter.
USB_SERIAL_DDK_SUCCESS = 31600000Operation success.
USB_SERIAL_DDK_INVALID_OPERATION = 31600001Invalid operation.
USB_SERIAL_DDK_INIT_ERROR = 31600002Initialization error.
USB_SERIAL_DDK_SERVICE_ERROR = 31600003Service error.
USB_SERIAL_DDK_MEMORY_ERROR = 31600004Memory-related errors, such as insufficient memory, memory data replication failure, or memory application fault.
USB_SERIAL_DDK_IO_ERROR = 31600005I/O error.
USB_SERIAL_DDK_DEVICE_NOT_FOUND = 31600006Device not found.

UsbSerial_FlowControl

enum UsbSerial_FlowControl

Description

Defines the flow control mode for the USB Serial DDK.

Since: 18

EnumDescription
USB_SERIAL_NO_FLOW_CONTROL = 0No flow control.
USB_SERIAL_SOFTWARE_FLOW_CONTROL = 1Software flow control.
USB_SERIAL_HARDWARE_FLOW_CONTROL = 2Hardware flow control.

UsbSerial_Parity

enum UsbSerial_Parity

Description

Defines the enums of the parity parameter used by the USB Serial DDK.

Since: 18

EnumDescription
USB_SERIAL_PARITY_NONE = 0No parity.
USB_SERIAL_PARITY_ODD = 1Odd parity.
USB_SERIAL_PARITY_EVEN = 2Even parity.

你可能感兴趣的鸿蒙文章

openharmony 鸿蒙 capi-scsiperipheralddk-scsiperipheral-request

openharmony 鸿蒙 capi-usbddk-usbconfigdescriptor

openharmony 鸿蒙 capi-hidddk

openharmony 鸿蒙 capi-usbddk

openharmony 鸿蒙 capi-hidddk-hid-absaxesarray

openharmony 鸿蒙 capi-scsiperipheralddk-scsiperipheral-response

openharmony 鸿蒙 capi-scsi-peripheral-api-h

openharmony 鸿蒙 capi-hidddk-hid-relaxesarray

openharmony 鸿蒙 js-apis-driver-deviceManager

openharmony 鸿蒙 capi-hidddk-hid-eventtypearray

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