adafruit / Adafruit_IO_Arduino

Arduino library to access Adafruit IO from WiFi, cellular, and ethernet modules.
Other
209 stars 108 forks source link

Calling AdafruitIO without managed network connection? #96

Closed blkirk closed 4 years ago

blkirk commented 4 years ago

Can someone provide an example of how to call AdafruitIO without having it manage your wifi/ethernet connection? (Assume that I have a connection and it's already up.)

non-working Example:

include "AdafruitIO.h"

define IO_USERNAME "XXXXXX"

define IO_KEY "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"

AdafruitIO_Ethernet io(IO_USERNAME, IO_KEY); AdafruitIO_Feed pina0 = io.feed("limetreea0"); AdafruitIO_Feed pind7 = io.feed("limetread7"); ...etc...

blkirk commented 4 years ago

This might be the answer, nulls :

include "AdafruitIO_WiFi.h"

define IO_USERNAME "XXXXXX"

define IO_KEY "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"

AdafruitIO_WiFi io(IO_USERNAME, IO_KEY, NULL, NULL);