wut  v1.7.0
Wii U Toolchain
Data Structures | Macros | Typedefs | Enumerations | Functions
Nsysccr_cdc_irda

InfraRed Data. More...

Collaboration diagram for Nsysccr_cdc_irda:

Data Structures

struct  CCRCDCIrdaConnectRequest
 
struct  CCRCDCIrdaConnectReply
 
struct  CCRCDCIrdaSendRequest
 
struct  CCRCDCIrdaSendReply
 
struct  CCRCDCIrdaReceiveRequest
 
struct  CCRCDCIrdaReceiveReply
 
struct  CCRCDCIrdaDisconnectRequest
 
struct  CCRCDCIrdaDisconnectReply
 
struct  CCRCDCIrdaSmallPacketHeader
 
struct  CCRCDCIrdaLargePacketHeader
 

Macros

#define CCR_CDC_IRDA_DATA_TRANSFER_SIZE   0x208
 The buffer size for data tranfers (send / receive) More...
 

Typedefs

typedef uint8_t CCRCDCIrdaCommand
 
typedef uint8_t CCRCDCIrdaBitrate
 
typedef uint8_t CCRCDCIrdaConnectionType
 
typedef struct CCRCDCIrdaConnectRequest CCRCDCIrdaConnectRequest
 
typedef struct CCRCDCIrdaConnectReply CCRCDCIrdaConnectReply
 
typedef struct CCRCDCIrdaSendRequest CCRCDCIrdaSendRequest
 
typedef struct CCRCDCIrdaSendReply CCRCDCIrdaSendReply
 
typedef struct CCRCDCIrdaReceiveRequest CCRCDCIrdaReceiveRequest
 
typedef struct CCRCDCIrdaReceiveReply CCRCDCIrdaReceiveReply
 
typedef struct CCRCDCIrdaDisconnectRequest CCRCDCIrdaDisconnectRequest
 
typedef struct CCRCDCIrdaDisconnectReply CCRCDCIrdaDisconnectReply
 
typedef struct CCRCDCIrdaSmallPacketHeader CCRCDCIrdaSmallPacketHeader
 
typedef struct CCRCDCIrdaLargePacketHeader CCRCDCIrdaLargePacketHeader
 

Enumerations

enum  CCRCDCIrdaCommandEnum {
  CCR_IRDA_COMMAND_CONNECT = 0 ,
  CCR_IRDA_COMMAND_SEND = 1 ,
  CCR_IRDA_COMMAND_RECEIVE = 2 ,
  CCR_IRDA_COMMAND_DISCONNECT = 3
}
 
enum  CCRCDCIrdaBitrateEnum {
  CCR_IRDA_BITRATE_115200 = 0 ,
  CCR_IRDA_BITRATE_96000 = 1 ,
  CCR_IRDA_BITRATE_72000 = 2 ,
  CCR_IRDA_BITRATE_57600 = 3 ,
  CCR_IRDA_BITRATE_48000 = 4 ,
  CCR_IRDA_BITRATE_38400 = 5 ,
  CCR_IRDA_BITRATE_36000 = 6 ,
  CCR_IRDA_BITRATE_24000 = 7 ,
  CCR_IRDA_BITRATE_19200 = 8 ,
  CCR_IRDA_BITRATE_18000 = 9 ,
  CCR_IRDA_BITRATE_12000 = 10 ,
  CCR_IRDA_BITRATE_9600 = 11 ,
  CCR_IRDA_BITRATE_7200 = 13 ,
  CCR_IRDA_BITRATE_6000 = 13 ,
  CCR_IRDA_BITRATE_4800 = 14 ,
  CCR_IRDA_BITRATE_3000 = 15
}
 
enum  CCRCDCIrdaConnectionTypeEnum {
  CCR_IRDA_CONNECTION_WAIT = 0 ,
  CCR_IRDA_CONNECTION_REQUIRE = 1 ,
  CCR_IRDA_CONNECTION_ANY = 2
}
 

Functions

int32_t CCRCDCPerIrdaControl (CCRCDCDestination dest, void *request, uint32_t requestSize, void *response, uint32_t responseSize)
 Controls IR of the GamePad. More...
 

Detailed Description

InfraRed Data.


Data Structure Documentation

◆ CCRCDCIrdaConnectRequest

struct CCRCDCIrdaConnectRequest

Definition at line 91 of file irda.h.

Data Fields
CCRCDCIrdaCommand command CCR_IRDA_COMMAND_CONNECT.
uint16_t timeout Timeout of the connection in ms.
CCRCDCIrdaBitrate bitrate Bitrate of the connection.
uint16_t receiveSize Amount of data which should be received from the other device.
uint8_t targetId The ID of the target device.
CCRCDCIrdaConnectionType type The type of the connect request.

◆ CCRCDCIrdaConnectReply

struct CCRCDCIrdaConnectReply

Definition at line 114 of file irda.h.

Data Fields
uint8_t result 0 on success

◆ CCRCDCIrdaSendRequest

struct CCRCDCIrdaSendRequest

Definition at line 122 of file irda.h.

Data Fields
CCRCDCIrdaCommand command CCR_IRDA_COMMAND_SEND.
uint16_t size The size of this request.
uint8_t data[0] Packet data starts here.

◆ CCRCDCIrdaSendReply

struct CCRCDCIrdaSendReply

Definition at line 136 of file irda.h.

Data Fields
uint8_t result 0 on success

◆ CCRCDCIrdaReceiveRequest

struct CCRCDCIrdaReceiveRequest

Definition at line 144 of file irda.h.

Data Fields
CCRCDCIrdaCommand command CCR_IRDA_COMMAND_RECEIVE.

◆ CCRCDCIrdaReceiveReply

struct CCRCDCIrdaReceiveReply

Definition at line 152 of file irda.h.

Data Fields
uint8_t result 0 on success
uint16_t size The size of this reply.
uint8_t data[0] Packet data starts here.

◆ CCRCDCIrdaDisconnectRequest

struct CCRCDCIrdaDisconnectRequest

Definition at line 166 of file irda.h.

Data Fields
CCRCDCIrdaCommand command CCR_IRDA_COMMAND_DISCONNECT.

◆ CCRCDCIrdaDisconnectReply

struct CCRCDCIrdaDisconnectReply

Definition at line 174 of file irda.h.

Data Fields
uint8_t result 0 on success

◆ CCRCDCIrdaSmallPacketHeader

struct CCRCDCIrdaSmallPacketHeader

Definition at line 182 of file irda.h.

Data Fields
uint8_t magic Magic value (needs to be set to 0xa5)
uint8_t sessionId ID of the session (gets filled out by the DRC before transmitting the packet)
uint8_t unk: 1
uint8_t isLarge: 1 0 for small packets
uint8_t dataSize: 6 Size of the actual data.
uint16_t receiveSize Amount of data which should be received from the other device.

◆ CCRCDCIrdaLargePacketHeader

struct CCRCDCIrdaLargePacketHeader

Definition at line 201 of file irda.h.

Data Fields
uint8_t magic Magic value (needs to be set to 0xa5)
uint8_t sessionId ID of the session (gets filled out by the DRC before transmitting the packet)
uint8_t unk: 1
uint8_t isLarge: 1 1 for large packets
uint16_t dataSize: 14 Size of the actual data.
uint16_t receiveSize Amount of data which should be received from the other device.

Macro Definition Documentation

◆ CCR_CDC_IRDA_DATA_TRANSFER_SIZE

#define CCR_CDC_IRDA_DATA_TRANSFER_SIZE   0x208

The buffer size for data tranfers (send / receive)

Definition at line 31 of file irda.h.

Typedef Documentation

◆ CCRCDCIrdaCommand

typedef uint8_t CCRCDCIrdaCommand

Definition at line 16 of file irda.h.

◆ CCRCDCIrdaBitrate

typedef uint8_t CCRCDCIrdaBitrate

Definition at line 17 of file irda.h.

◆ CCRCDCIrdaConnectionType

typedef uint8_t CCRCDCIrdaConnectionType

Definition at line 18 of file irda.h.

◆ CCRCDCIrdaConnectRequest

Definition at line 18 of file irda.h.

◆ CCRCDCIrdaConnectReply

Definition at line 18 of file irda.h.

◆ CCRCDCIrdaSendRequest

Definition at line 18 of file irda.h.

◆ CCRCDCIrdaSendReply

Definition at line 18 of file irda.h.

◆ CCRCDCIrdaReceiveRequest

Definition at line 18 of file irda.h.

◆ CCRCDCIrdaReceiveReply

Definition at line 18 of file irda.h.

◆ CCRCDCIrdaDisconnectRequest

Definition at line 18 of file irda.h.

◆ CCRCDCIrdaDisconnectReply

Definition at line 18 of file irda.h.

◆ CCRCDCIrdaSmallPacketHeader

Definition at line 18 of file irda.h.

◆ CCRCDCIrdaLargePacketHeader

Definition at line 18 of file irda.h.

Enumeration Type Documentation

◆ CCRCDCIrdaCommandEnum

Enumerator
CCR_IRDA_COMMAND_CONNECT 

Initiate a new connection.

CCR_IRDA_COMMAND_SEND 

Send data.

CCR_IRDA_COMMAND_RECEIVE 

Receive data.

CCR_IRDA_COMMAND_DISCONNECT 

Disconnect.

Definition at line 33 of file irda.h.

◆ CCRCDCIrdaBitrateEnum

Enumerator
CCR_IRDA_BITRATE_115200 

115200 bits-per-second

CCR_IRDA_BITRATE_96000 

96000 bits-per-second

CCR_IRDA_BITRATE_72000 

72000 bits-per-second

CCR_IRDA_BITRATE_57600 

57600 bits-per-second

CCR_IRDA_BITRATE_48000 

48000 bits-per-second

CCR_IRDA_BITRATE_38400 

38400 bits-per-second

CCR_IRDA_BITRATE_36000 

36000 bits-per-second

CCR_IRDA_BITRATE_24000 

24000 bits-per-second

CCR_IRDA_BITRATE_19200 

19200 bits-per-second

CCR_IRDA_BITRATE_18000 

18000 bits-per-second

CCR_IRDA_BITRATE_12000 

12000 bits-per-second

CCR_IRDA_BITRATE_9600 

9600 bits-per-second

CCR_IRDA_BITRATE_7200 

7200 bits-per-second

CCR_IRDA_BITRATE_6000 

6000 bits-per-second

CCR_IRDA_BITRATE_4800 

4800 bits-per-second

CCR_IRDA_BITRATE_3000 

3000 bits-per-second

Definition at line 45 of file irda.h.

◆ CCRCDCIrdaConnectionTypeEnum

Enumerator
CCR_IRDA_CONNECTION_WAIT 

Wait for another device to start a connection.

CCR_IRDA_CONNECTION_REQUIRE 

Initiate a new connection.

CCR_IRDA_CONNECTION_ANY 

Don't require a connection.

Definition at line 81 of file irda.h.

Function Documentation

◆ CCRCDCPerIrdaControl()

int32_t CCRCDCPerIrdaControl ( CCRCDCDestination  dest,
void *  request,
uint32_t  requestSize,
void *  response,
uint32_t  responseSize 
)

Controls IR of the GamePad.

Note that the GamePad expects data in a specific packet format.

Parameters
destThe device to get the mac address from. See CCRCDCDestinationEnum.
requestThe request payload sent to the GamePad.
requestSizeThe size of the request payload.
responseThe response payload received from the GamePad.
responseSizeThe size of the response payload.
Returns
0 on success.