Mega + ard wifi shield + usb host shield


I have an Mega with a arduino wifi shield and an usb host shield from circuits@home on top.
Pin 10 is changed to pin 8 for the SPI

I want to do something now with wifi
But when i take a basic example for wifi like this

#include <WiFi.h>

char ssid[] = "yourNetwork";     //  your network SSID (name) 
char pass[] = "12345678";    // your network password
int status = WL_IDLE_STATUS;     // the Wifi radio's status

void setup() {
  // initialize serial:

  // attempt to connect using WPA2 encryption:
  Serial.println("Attempting to connect to WPA network...");
  status = WiFi.begin(ssid, pass);

  // if you're not connected, stop here:
  if ( status != WL_CONNECTED) { 
    Serial.println("Couldn't get a wifi connection");
  // if you are connected, print out info about the connection:
  else {
    Serial.println("Connected to network");

void loop() {
  // do nothing

Then it is only running when i remove the usb shield.
When i attache the usb shield again it sometime scan the wifi networks
But most times it give errors.

I checked all the data connection and there is no double used pin or something like that.

Anyone any idea?