26 #define EP_MAXPKTSIZE 32 // Max size for data via USB 29 #define XBOX_CONTROL_PIPE 0 30 #define XBOX_INPUT_PIPE 1 31 #define XBOX_OUTPUT_PIPE 2 34 #define XBOX_VID 0x045E // Microsoft Corporation 35 #define MADCATZ_VID 0x1BAD // For unofficial Mad Catz controllers 36 #define JOYTECH_VID 0x162E // For unofficial Joytech controllers 38 #define XBOX_OLD_PID1 0x0202 // Original Microsoft Xbox controller (US) 39 #define XBOX_OLD_PID2 0x0285 // Original Microsoft Xbox controller (Japan) 40 #define XBOX_OLD_PID3 0x0287 // Microsoft Microsoft Xbox Controller S 41 #define XBOX_OLD_PID4 0x0289 // Smaller Microsoft Xbox controller (US) 43 #define XBOX_MAX_ENDPOINTS 3 62 uint8_t
Init(uint8_t parent, uint8_t port,
bool lowspeed);
96 virtual bool VIDPIDOK(uint16_t vid, uint16_t pid) {
140 pFuncOnInit = funcOnInit;
161 void (*pFuncOnInit)(void);
167 uint8_t OldButtonState;
168 uint8_t ButtonClickState;
171 uint8_t buttonValues[8];
172 uint8_t oldButtonValues[8];
173 bool buttonClicked[8];
180 void printReport(uint16_t length);
183 void XboxCommand(uint8_t* data, uint16_t nbytes);
void attachOnInit(void(*funcOnInit)(void))
virtual uint8_t GetAddress()
void setRumbleOn(uint8_t lValue, uint8_t rValue)
EpInfo epInfo[XBOX_MAX_ENDPOINTS]
int16_t getAnalogHat(AnalogHatEnum a)
uint8_t Init(uint8_t parent, uint8_t port, bool lowspeed)
#define XBOX_MAX_ENDPOINTS
bool getButtonClick(ButtonEnum b)
uint8_t getButtonPress(ButtonEnum b)
virtual bool VIDPIDOK(uint16_t vid, uint16_t pid)