mega 2560 w/adafruit CC33000 w/sparkfun library

Up till i now i've been using an adafruit CC3000 with Sparkfun libraries in order to post to m2x. Thus far, the connection part has been working fine.

However, now that i have gone to the mega for additionally memory, i cannot seem to get connected to the network using the sparkfun libraries. It kicks out an AP connection error message. I loaded up a basic example from each library, and the adafruit library works fine.

i would have thought that maybe it was an initialization problem due to sockets or whatever, but the serial monitor reports that it is initializing fine.

When i first tried to get connected to this website i tried to use the adafruit libraries etc, but i could never get a good compile or good connection with the server. I suppose i can include libraries in this post, but im hoping someone else may have dealt with this issue?

thanks

Ok so i think the problem is definitely in the header, so this is the direction i’ve taken:

sparkfun header:

#define CC3000_INT      3   // Needs to be an interrupt pin (D2/D3)
#define CC3000_EN       5   // Can be any digital pin
#define CC3000_CS       10  // Preferred is pin 10 on Uno

// Connection info data lengths
#define IP_ADDR_LEN     4   // Length of IP address in bytes

// WiFi Constants
char ap_ssid[] = "HOME-61B2";                  // SSID of network
char ap_password[] = "REMOVED";          // Password of network
unsigned int ap_security = WLAN_SEC_WPA2; // Security of network
unsigned int timeout = 30000;             // Milliseconds



// Global Variables
SFE_CC3000 wifi = SFE_CC3000(CC3000_INT, CC3000_EN, CC3000_CS);
SFE_CC3000_Client client = SFE_CC3000_Client(wifi);
M2XStreamClient m2xClient(&client, m2xKey);

stock adafruit header:

#include <Adafruit_CC3000.h>
#include <ccspi.h>
#include <SPI.h>
#include <string.h>
#include "utility/debug.h"

// These are the interrupt and control pins
#define ADAFRUIT_CC3000_IRQ   3  // MUST be an interrupt pin!
// These can be any two pins
#define ADAFRUIT_CC3000_VBAT  5
#define ADAFRUIT_CC3000_CS    10
// Use hardware SPI for the remaining pins
// On an UNO, SCK = 13, MISO = 12, and MOSI = 11
Adafruit_CC3000 cc3000 = Adafruit_CC3000(ADAFRUIT_CC3000_CS, ADAFRUIT_CC3000_IRQ, ADAFRUIT_CC3000_VBAT,
                                         SPI_CLOCK_DIVIDER); // you can change this clock speed

#define WLAN_SSID       "HOME-61B2"           // cannot be longer than 32 characters
#define WLAN_PASS       "0C6B7DEB3241400F"
// Security can be WLAN_SEC_UNSEC, WLAN_SEC_WEP, WLAN_SEC_WPA or WLAN_SEC_WPA2
#define WLAN_SECURITY   WLAN_SEC_WPA2

#define IDLE_TIMEOUT_MS  3000      // Amount of time to wait (in milliseconds) with no data 
                                   // received before closing the connection.  If you know the server

my failed attempt to combine:

#include <SPI.h>
#include <Adafruit_CC3000.h>
#include <ccspi.h>
#include <jsonlite.h>
#include <M2XStreamClient.h>
#include <Wire.h>
//#include "M2XStreamClient.h"

// Parameters
#define POST_DELAY_MS   10000 // Post to stream every 10 seconds


// Connection info data lengths
#define IP_ADDR_LEN     4   // Length of IP address in bytes

// WiFi Constants
#define WLAN_SSID       "HOME-61B2"           // cannot be longer than 32 characters
#define WLAN_PASS       "REMOVED"
// Security can be WLAN_SEC_UNSEC, WLAN_SEC_WEP, WLAN_SEC_WPA or WLAN_SEC_WPA2
#define WLAN_SECURITY   WLAN_SEC_WPA2

#define IDLE_TIMEOUT_MS  3000


// Global Variables
// These are the interrupt and control pins
#define ADAFRUIT_CC3000_IRQ   3  // MUST be an interrupt pin!
// These can be any two pins
#define ADAFRUIT_CC3000_VBAT  5
#define ADAFRUIT_CC3000_CS    10
// Use hardware SPI for the remaining pins
// On an UNO, SCK = 13, MISO = 12, and MOSI = 11
Adafruit_CC3000 cc3000 = Adafruit_CC3000(ADAFRUIT_CC3000_CS, ADAFRUIT_CC3000_IRQ, ADAFRUIT_CC3000_VBAT,
SPI_CLOCK_DIVIDER); // you can change this clock speed

Adafruit_CC3000 wifi = Adafruit_CC3000(ADAFRUIT_CC3000_CS, ADAFRUIT_CC3000_IRQ, ADAFRUIT_CC3000_VBAT);
Adafruit_CC3000_Client client = Adafruit_CC3000_Client(wifi);

M2XStreamClient m2xClient(&clientm2xKey);

the error report for the above is:

Sketch1.ino:72:60: error: no matching function for call to 'Adafruit_CC3000_Client::Adafruit_CC3000_Client(Adafruit_CC3000&)'
:Adafruit_CC3000_Client client = Adafruit_CC3000_Client(wifi);
:^
Sketch1.ino:candidates are
Sketch1.ino:In file included from
Adafruit_CC3000.h:Adafruit_CC3000_Client(const Adafruit_CC3000_Client&)
:Adafruit_CC3000_Client(const Adafruit_CC3000_Client& copy);
:^
Adafruit_CC3000.h:no known conversion for argument 1 from 'Adafruit_CC3000' to 'const Adafruit_CC3000_Client&'
Adafruit_CC3000.h:Adafruit_CC3000_Client()
:Adafruit_CC3000_Client(void);
:^
Adafruit_CC3000.h:candidate expects 0 arguments, 1 provided
Adafruit_CC3000.h:Adafruit_CC3000_Client(uint16_t)
:Adafruit_CC3000_Client(uint16_t s);
:^
Adafruit_CC3000.h:no known conversion for argument 1 from 'Adafruit_CC3000' to 'uint16_t {aka unsigned int}'
M2XStreamClient.h:In file included from
Sketch1.ino:from

EDIT: upgrading firmware to 1.4 solved the problem… for now…