13
13
14
14
#include " AdafruitIO_WINC1500.h"
15
15
16
- Adafruit_WINC1500 WiFi (WINC_CS, WINC_IRQ, WINC_RST);
17
16
18
17
AdafruitIO_WINC1500::AdafruitIO_WINC1500 (const char *user, const char *key, const char *ssid, const char *pass):AdafruitIO(user, key)
19
18
{
20
19
_ssid = ssid;
21
20
_pass = pass;
22
- _client = new Adafruit_WINC1500SSLClient ;
21
+ _client = new WiFiSSLClient ;
23
22
_mqtt = new Adafruit_MQTT_Client (_client, _host, _port);
24
23
}
25
24
26
25
AdafruitIO_WINC1500::AdafruitIO_WINC1500 (const __FlashStringHelper *user, const __FlashStringHelper *key, const __FlashStringHelper *ssid, const __FlashStringHelper *pass):AdafruitIO(user, key)
27
26
{
28
27
_ssid = (const char *)ssid;
29
28
_pass = (const char *)pass;
30
- _client = new Adafruit_WINC1500SSLClient ;
29
+ _client = new WiFiSSLClient ;
31
30
_mqtt = new Adafruit_MQTT_Client (_client, _host, _port);
32
31
}
33
32
@@ -42,9 +41,7 @@ AdafruitIO_WINC1500::~AdafruitIO_WINC1500()
42
41
void AdafruitIO_WINC1500::_connect ()
43
42
{
44
43
45
- pinMode (WINC_EN, OUTPUT);
46
- digitalWrite (WINC_EN, HIGH);
47
- delay (100 );
44
+ WiFi.setPins (WINC_CS, WINC_IRQ, WINC_RST, WINC_EN);
48
45
49
46
// no shield? bail
50
47
if (WiFi.status () == WL_NO_SHIELD)
0 commit comments