Yep by default the CC3000 sketches will ask your router for the DNS server using DHCP. If you can, check the router configuration to see if it has any DHCP or DNS server configuration which might need to be updated to send the 192.168.2.1 value.
One other thing to try, let's see if setting a static IP address and explicit DNS servers help get you connected to your network. Grab the latest library code from github and open the buildtest example. Scroll down to this section of code:
Code: Select all
/* Optional: Set a static IP address instead of using DHCP.
Note that the setStaticIPAddress function will save its state
in the CC3000's internal non-volatile memory and the details
will be used the next time the CC3000 connects to a network.
This means you only need to call the function once and the
CC3000 will remember the connection details. To switch back
to using DHCP, call the setDHCP() function (again only needs
to be called once).
*/
/*
uint32_t ipAddress = cc3000.IP2U32(192, 168, 1, 19);
uint32_t netMask = cc3000.IP2U32(255, 255, 255, 0);
uint32_t defaultGateway = cc3000.IP2U32(192, 168, 1, 1);
uint32_t dns = cc3000.IP2U32(8, 8, 4, 4);
if (!cc3000.setStaticIPAddress(ipAddress, netMask, defaultGateway, dns)) {
Serial.println(F("Failed to set static IP!"));
while(1);
}
*/
Uncomment the block of code and fill in the details for setting a static IP. You probably want an IP in the 192.168.2.x range. If you know the explicit netmask and default gateway values for your router then drop those in, otherwise I think 255.255.255.0 and 192.168.2.1 are what you want. Finally for the DNS server try using the 8.8.4.4 value for Google's DNS servers to start with now since it's a known working server. Run the sketch with those changes and let's see if it can connect with the 8.8.4.4 DNS server.