Skip to content

Commit 2c2c63f

Browse files
committed
Updated example
1 parent d905de9 commit 2c2c63f

File tree

4 files changed

+5
-117
lines changed

4 files changed

+5
-117
lines changed

examples/test_getting_started_18_01_ubi/cloudProperties.h renamed to examples/test_getting_started_10_02_ubi/cloudProperties.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
#include <GSMConnectionManager.h>
1+
#include <WiFiConnectionManager.h>
22

3-
ConnectionManager *ArduinoIoTPreferredConnection = new GSMConnectionManager(
4-
SECRET_GSMPIN, SECRET_GPRSAPN, SECRET_GPRSLOGIN, SECRET_GPRSPWD);
3+
ConnectionManager *ArduinoIoTPreferredConnection = new WiFiConnectionManager(
4+
SECRET_SSID, SECRET_PASS);
55

66
void onLedSwitchChange();
77
void onIntValueChange();

examples/test_getting_started_18_01_ubi/test_getting_started_18_01_ubi.ino renamed to examples/test_getting_started_10_02_ubi/test_getting_started_10_02_ubi.ino

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -71,13 +71,11 @@ void loop() {
7171
checkNetworkConnection();
7272
}
7373

74-
ConnectionManager *conn = new GSMConnectionManager("", "", "", "");
75-
7674
void initConnection() {
7775
ArduinoIoTPreferredConnection->init();
7876

7977
// begin of the ArduinoIoTCloud
80-
if (!ArduinoCloud.begin(conn)) {
78+
if (!ArduinoCloud.begin()) {
8179
Serial.println("Starting Arduino Cloud failed!");
8280
while (true);
8381
}
@@ -107,7 +105,7 @@ void checkNetworkConnection() {
107105
Serial.println("..Reconnected to the Nework!");
108106

109107
// Call the reconnect method to clean up the ArduinoCloud connection
110-
while (!ArduinoCloud.reconnect(ArduinoIoTPreferredConnection->getClient())) {
108+
while (!ArduinoCloud.reconnect()) {
111109
delay(ARDUINO_IOT_CLOUD_CONNECTION_TIMEOUT);
112110
}
113111

examples/test_getting_started_18_01_ubi/WiFi_MANAGER.h

Lines changed: 0 additions & 110 deletions
This file was deleted.

0 commit comments

Comments
 (0)