USB Host Shield Library 2.0

I am having trouble understand a portion of the Arduino USB Host Shield Library 2.0. I am trying to use an Xbox 360 controller to control a quad copter, and need to understand the setup used in the example sketch so I can write my own code for the controls.

Here is the portion of code for reference.

  if (Usb.Init() == -1) {
    Serial.print(F("\r\nOSC did not start"));
    while (1); //halt
  }
  Serial.print(F("\r\nXbox Wireless Receiver Library Started"));

I understand that this seems to be a failsafe to make sure the background objects are ready for the sketch to move on, but I'm having trouble understanding what causes Usb.Init to return different values.

Here is the portion of code from the Usb.cpp that partains to what is being done so far in the sketch.

/* constructor */
USB::USB() : bmHubPre(0) {
        usb_task_state = USB_DETACHED_SUBSTATE_INITIALIZE; //set up state machine
        init();
}

/* Initialize data structures */
void USB::init() {
        //devConfigIndex = 0;
        bmHubPre = 0;
}

I have tried searching everywhere for more information on this function but have not found anything. If anyone could please point me in the right direction, it would be much apreciated.

The source code is all provided at https://github.com/felis/USB_Host_Shield_2.0 if I am missing information.

If the Init is failing, there is hardware or wiring problem so double check the hardware. I doubt looking the source code is helpful.

Usb is a subclass of MAX3421e so Usb.Init() resolves to MAX3421e::Init which is in usbhost.h.