C# Class CorsairLinkPlusPlus.Driver.CorsairLink.USB.BaseUSBDevice

Inheritance: CorsairLinkPlusPlus.Common.BaseDevice
显示文件 Open project: Doridian/CorsairLinkPlusPlus

Protected Properties

Property Type Description
commandNo int
hidDevice HidSharp.HidDevice

Public Methods

Method Description
GetLocalDeviceID ( ) : string
GetUsedChannels ( ) : byte>.Dictionary
Refresh ( bool volatileOnly ) : void
SendCommand ( byte opcode, byte channel, byte command ) : byte[]

Protected Methods

Method Description
GetSubDevicesInternal ( ) : List
MakeCommand ( byte opcode, byte channel, byte response ) : byte[]
ParseResponse ( byte response ) : byte[]

Private Methods

Method Description
BaseUSBDevice ( CorsairRootDevice root, HidDevice hidDevice ) : CorsairLinkPlusPlus.Common
FixUpDeviceID ( string id ) : string
GetDeviceOnChannel ( byte channel ) : BaseLinkDevice
GetDeviceOnChannel ( byte channel, byte deviceType ) : BaseLinkDevice
ReadRegister ( byte register, byte channel, byte bytes ) : byte[]
ReadSingleByteRegister ( byte register, byte channel ) : byte
SleepAfterFailure ( ) : bool
WriteRegister ( byte register, byte channel, byte bytes, bool verify = false ) : void
WriteSingleByteRegister ( byte register, byte channel, byte value, bool verify = false ) : void

Method Details

GetLocalDeviceID() public method

public GetLocalDeviceID ( ) : string
return string

GetSubDevicesInternal() protected method

protected GetSubDevicesInternal ( ) : List
return List

GetUsedChannels() public method

public GetUsedChannels ( ) : byte>.Dictionary
return byte>.Dictionary

MakeCommand() protected abstract method

protected abstract MakeCommand ( byte opcode, byte channel, byte response ) : byte[]
opcode byte
channel byte
response byte
return byte[]

ParseResponse() protected method

protected ParseResponse ( byte response ) : byte[]
response byte
return byte[]

Refresh() public method

public Refresh ( bool volatileOnly ) : void
volatileOnly bool
return void

SendCommand() public method

public SendCommand ( byte opcode, byte channel, byte command ) : byte[]
opcode byte
channel byte
command byte
return byte[]

Property Details

commandNo protected_oe property

protected int commandNo
return int

hidDevice protected_oe property

protected HidDevice,HidSharp hidDevice
return HidSharp.HidDevice