#include <dxd_usb.h>
|
| enum | speed {
low =::kUSBHostConnectionSpeedLow
, full =::kUSBHostConnectionSpeedFull
, high =::kUSBHostConnectionSpeedHigh
, usb1 =full
,
usb2 =high
} |
|
| os_result | clear () |
| unsigned char | configuration () const |
| os_result | configuration (unsigned char configuration) |
| unsigned char | configurations () const |
| decltype(dx::usb::descriptor::device) | descriptor () const |
| | IOKit: request the USB device descriptor.
|
| uint64_t | frame () const |
| ::IOUSBHostInterface * | interface (unsigned char index, unsigned char setting=0) |
| | IOKit: USB interface.
|
| virtual os_result | ioctl (unsigned int ioctl, const void *, size_t size_in, void *out, size_t size_out, size_t &size) |
| | control I/O handler, reached through client::ioctl()
|
| | operator::IOUSBHostDevice * () const |
| | IOKit: IOUSBDevice* implicit cast.
|
| template<typename data_t> |
| os_result | request (const dx::usb::control &control, data_t &data) |
| | IOKit: synchronously sends an USB request.
|
| os_result | request (const dx::usb::control &control, void *data, size_t &size) |
| speed | speed () const |
| os_result | state () const |
| os_result | string (unsigned char idx, char *string, unsigned char &chars, dx::usb::language language=dx::usb::language::standard) |
| | IOKit: request the USB string descriptor for the index.
|
| template<typename string_t> |
| os_result | string (unsigned char idx, string_t &string) |
◆ speed
- Todo
- enum class
| Enumerator |
|---|
| low | |
| full | |
| high | |
| usb1 | |
| usb2 | |
◆ clear()
◆ client_create()
| virtual client * dxd::device::client_create |
( |
| ) |
|
|
inlineprotectedvirtualinherited |
◆ close_interfaces()
| void dxd::usb_device::close_interfaces |
( |
| ) |
|
|
inlineprotected |
◆ conclude()
| void dxd::usb_device::conclude |
( |
| ) |
|
|
inlineoverrideprotectedvirtual |
IOKit: USB conclude.
This method:
- iterates over and closes all USB interfaces
- deselects USB configuration
- closes the USB device from exclusive access
- De-selects previosly selected USB configuration,
- Todo
- investigate if reset() is still needed here
- closes the USB device, so another driver has the chance to match against (important: this driver will not unload otherwise)
Reimplemented from dxd::device.
◆ configuration() [1/2]
| unsigned char dxd::usb_device::configuration |
( |
| ) |
const |
|
inline |
◆ configuration() [2/2]
| os_result dxd::usb_device::configuration |
( |
unsigned char | configuration | ) |
|
|
inline |
◆ configurations()
| unsigned char dxd::usb_device::configurations |
( |
| ) |
const |
|
inline |
◆ descriptor()
| decltype(dx::usb::descriptor::device) dxd::usb_device::descriptor |
( |
| ) |
const |
|
inline |
IOKit: request the USB device descriptor.
- Deprecated
◆ frame()
| uint64_t dxd::usb_device::frame |
( |
| ) |
const |
|
inline |
◆ interface()
| ::IOUSBHostInterface * dxd::usb_device::interface |
( |
unsigned char | index, |
|
|
unsigned char | setting = 0 ) |
|
inline |
IOKit: USB interface.
Selects the USB interface
checks interface, if it fails: was it configured?
and selects the (alternate) setting
- Parameters
-
| index | index of the USB interface in the USB configuration |
| setting | setting # of the USB interface |
◆ ioctl()
| virtual os_result dxd::device::ioctl |
( |
unsigned int | ioctl, |
|
|
const void * | , |
|
|
size_t | size_in, |
|
|
void * | out, |
|
|
size_t | size_out, |
|
|
size_t & | size ) |
|
inlinevirtualinherited |
◆ launch()
|
|
inlineoverrideprotectedvirtual |
IOKit: USB launch.
This method:
- opens the USB device for exclusive access,
- selects default USB configuration
- iterates over and opens all USB interfaces
Reimplemented from dxd::device.
◆ open_interfaces()
| os_result dxd::usb_device::open_interfaces |
( |
| ) |
|
|
inlineprotected |
◆ operator::IOUSBHostDevice *()
| dxd::usb_device::operator::IOUSBHostDevice * |
( |
| ) |
const |
|
inline |
IOKit: IOUSBDevice* implicit cast.
◆ request() [1/2]
template<typename data_t>
IOKit: synchronously sends an USB request.
- Todo
- USB device control request timeout
- Parameters
-
| control | the USB request control defining the request type |
| data | data to transmit or receive |
◆ request() [2/2]
- Parameters
-
| control | the USB request control defining the request type |
| data | data to transmit or receive |
| size | size of the actual transaction |
◆ speed()
◆ start()
| bool dxd::usb_device::start |
( |
::IOService * | provider | ) |
|
|
inlineoverrideprotected |
◆ state()
- Todo
- find out if isInactive() is equivalent to getState()
◆ string() [1/2]
IOKit: request the USB string descriptor for the index.
- Parameters
-
| idx | index of the string to request |
| string | preallocated string buffer |
| chars | number of characters returned |
◆ string() [2/2]
template<typename string_t>
| os_result dxd::usb_device::string |
( |
unsigned char | idx, |
|
|
string_t & | string ) |
|
inline |
◆ bus
| ::DEVICE_OBJECT* dxd::device::bus |
|
inherited |
◆ pdo
| ::DEVICE_OBJECT* dxd::device::pdo |
|
inherited |
◆ status
◆ [struct]
| struct { ... } dxd::device::wdm |
The documentation for this class was generated from the following file: