0

Problem Running AdafruitIO Examples on UNO
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Problem Running AdafruitIO Examples on UNO

by Fruitcakejr on Mon Jan 01, 2018 12:07 am

I'm having a hard time running any of the examples that use a config.h on a UNO with a W5500 Ethernet shield.
It compiles fine but when run it I get in the serial monitor:

Connecting to Adafruit IOConnecting to Adafruit IO........

I looks like it's just not making a connection and is a config.h issue. Programs that don't use a config.h like the "Adafruit MQTT Library Ethernet Example" run fine.
I received my Arduino a couple of weeks ago so I'm still rather new at it.
Thanks for any help!
.
My config.h at last try for the Adafruit IO Publish Example:

Code: Select all | TOGGLE FULL SIZE

/************************ Adafruit IO Config *******************************/

// visit io.adafruit.com if you need to create an account,
// or if you need your Adafruit IO key.
#define IO_USERNAME    "myname"
#define IO_KEY         "mycode"

/******************************* WIFI **************************************/

// the AdafruitIO_WiFi client will work with the following boards:
//   - HUZZAH ESP8266 Breakout -> https://www.adafruit.com/products/2471
//   - Feather HUZZAH ESP8266 -> https://www.adafruit.com/products/2821
//   - Feather M0 WiFi -> https://www.adafruit.com/products/3010
//   - Feather WICED -> https://www.adafruit.com/products/3056

//#define WIFI_SSID       "your_ssid"
//#define WIFI_PASS       "your_pass"

// comment out the following two lines if you are using fona or ethernet
//#include "AdafruitIO_WiFi.h"
//AdafruitIO_WiFi io(IO_USERNAME, IO_KEY, WIFI_SSID, WIFI_PASS);


/******************************* FONA **************************************/

// the AdafruitIO_FONA client will work with the following boards:
//   - Feather 32u4 FONA -> https://www.adafruit.com/product/3027

// uncomment the following two lines for 32u4 FONA,
// and comment out the AdafruitIO_WiFi client in the WIFI section
// #include "AdafruitIO_FONA.h"
// AdafruitIO_FONA io(IO_USERNAME, IO_KEY);


/**************************** ETHERNET ************************************/

// the AdafruitIO_Ethernet client will work with the following boards:
//   - Ethernet FeatherWing -> https://www.adafruit.com/products/3201

// uncomment the following two lines for ethernet,
// and comment out the AdafruitIO_WiFi client in the WIFI section
 #include "AdafruitIO_Ethernet.h"
 AdafruitIO_Ethernet io(IO_USERNAME, IO_KEY);

#include <Ethernet2.h>        //  Tried this, same as above
#include <EthernetClient.h>
#include <Dns.h>
#include <Dhcp.h>


Fruitcakejr
 
Posts: 10
Joined: Tue Dec 05, 2017 1:15 pm

Please be positive and constructive with your questions and comments.