CC3000 Breakout and Teensy 2.0

For other supported Arduino products from Adafruit: Shields, accessories, etc.

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
User avatar
ksum
 
Posts: 19
Joined: Mon Sep 16, 2013 4:04 pm

Re: CC3000 Breakout and Teensy 2.0

Post by ksum »

I found a solution to the problem of the CC3000 acting weird when trying to reconnect to a website at
specific intervals.
  • Start the CC3000
    Connect to the network
    Check DHCP
    Resolve the website's IP
    Download the needed data
    Use this code to disconnect from the network

Code: Select all

while (cc3000.checkConnected())
{
    cc3000.disconnect();
    delay(1000);
}
I've been running this in my project for about an hour now with the interval set at 1 minute
and it hasn't missed a connection yet. I guess the CC3000 just doesn't like to stay connected
to a network for long periods.

User avatar
adafruit_support_mike
 
Posts: 67485
Joined: Thu Feb 11, 2010 2:51 pm

Re: CC3000 Breakout and Teensy 2.0

Post by adafruit_support_mike »

Wifi connections are much more vulnerable to noise and interference than wired connections, so disconnecting and reconnecting is a good idea.

Glad to hear it's working for you!

User avatar
ksum
 
Posts: 19
Joined: Mon Sep 16, 2013 4:04 pm

Re: CC3000 Breakout and Teensy 2.0

Post by ksum »

Now that I think about it, most WiFi clients will automatically reconnect.
The CC3000 is just a dumb device and won't reconnect unless the app
tells it to. I don't know why I was expecting it to be smarter than that. :)

User avatar
adafruit_support_mike
 
Posts: 67485
Joined: Thu Feb 11, 2010 2:51 pm

Re: CC3000 Breakout and Teensy 2.0

Post by adafruit_support_mike »

Welcome to the Maker mindset. ;-)

Today's consumer electronics do a huge amount of work behind the scenes to present the appearance of "just working". It's hard to appreciate how much effort that takes until you pop the hood and start tinkering with the pieces.

Our bottom-of-page quote file contains many entries to the effect of "simplicity is hard work".

Locked
Please be positive and constructive with your questions and comments.

Return to “Other Arduino products from Adafruit”