Skip to content

Commit 6c5f0ea

Browse files
improving examples
1 parent 564fcfc commit 6c5f0ea

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

libraries/lwIpWrapper/examples/ethernet_bare_lwipc33/ethernet_bare_lwipc33.ino

+6-2
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,13 @@ void setup() {
3636

3737
Serial.println("Renesas file download example");
3838

39+
IPAddress ip(192, 168, 10, 130);
40+
IPAddress gw(192, 168, 10, 1);
41+
IPAddress nm(255, 255, 255, 0);
42+
3943
DEBUG_INFO("Setting up netif");
40-
// Ethernet.begin(&ip, &nm, &gw);
41-
Ethernet.begin();
44+
Ethernet.begin(ip, nm, gw);
45+
// Ethernet.begin();
4246

4347
DEBUG_INFO("Begin of reception\n\n");
4448
debug_start = millis();

libraries/lwIpWrapper/examples/wifi_bare_lwipc33/wifi_bare_lwipc33.ino

+2-3
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,9 @@ void setup() {
3737

3838
Serial.println("Renesas file download example");
3939

40-
int res = 0;
4140
DEBUG_INFO("Connecting to AP");
42-
while((res=WiFi.begin(SSID, SECRET_PASS)) != 1) {
43-
DEBUG_INFO("Connection failed retry: %d", res);
41+
while(WiFi.begin(SSID, SECRET_PASS) != WL_CONNECTED) {
42+
DEBUG_INFO("Connection failed retry");
4443
delay(1000);
4544
}
4645
DEBUG_INFO("Connected to AP");

0 commit comments

Comments
 (0)