Skip to content

Add Uno R4 WiFi support to examples #94

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
ShortArrow opened this issue Nov 19, 2023 · 1 comment · Fixed by #90
Closed

Add Uno R4 WiFi support to examples #94

ShortArrow opened this issue Nov 19, 2023 · 1 comment · Fixed by #90
Assignees
Labels
topic: documentation Related to documentation for the project type: enhancement Proposed improvement

Comments

@ShortArrow
Copy link

ShortArrow commented Nov 19, 2023

Expected

Need const like UNO_R4_WIFI.
And include WiFiS3.h.

Note: this is tested by my Uno R4 WiFi.

#include <ArduinoMqttClient.h>
#include <WiFiS3.h>
#include "arduino_secrets.h"

Actual

#if defined(ARDUINO_SAMD_MKRWIFI1010) || defined(ARDUINO_SAMD_NANO_33_IOT) || defined(ARDUINO_AVR_UNO_WIFI_REV2)
#include <WiFiNINA.h>
#elif defined(ARDUINO_SAMD_MKR1000)
#include <WiFi101.h>
#elif defined(ARDUINO_ARCH_ESP8266)
#include <ESP8266WiFi.h>
#elif defined(ARDUINO_PORTENTA_H7_M7) || defined(ARDUINO_NICLA_VISION) || defined(ARDUINO_ARCH_ESP32) || defined(ARDUINO_GIGA)
#include <WiFi.h>
#endif

#if defined(ARDUINO_SAMD_MKRWIFI1010) || defined(ARDUINO_SAMD_NANO_33_IOT) || defined(ARDUINO_AVR_UNO_WIFI_REV2)
#include <WiFiNINA.h>
#elif defined(ARDUINO_SAMD_MKR1000)
#include <WiFi101.h>
#elif defined(ARDUINO_ARCH_ESP8266)
#include <ESP8266WiFi.h>
#elif defined(ARDUINO_PORTENTA_H7_M7) || defined(ARDUINO_NICLA_VISION) || defined(ARDUINO_ARCH_ESP32) || defined(ARDUINO_GIGA)
#include <WiFi.h>
#endif

@ShortArrow ShortArrow changed the title Uno R4 is work with #include <WiFiS3.h> about example sketches Uno R4 is work with #include <WiFiS3.h>, about example sketches Nov 19, 2023
@per1234 per1234 changed the title Uno R4 is work with #include <WiFiS3.h>, about example sketches Add Uno R4 WiFi support to examples Nov 20, 2023
@per1234 per1234 added type: enhancement Proposed improvement topic: documentation Related to documentation for the project labels Nov 20, 2023
@jwilleke
Copy link

Works for me with

#include <ArduinoMqttClient.h>
#include <SPI.h>
#include <PubSubClient.h>
#include "WiFi.h"
#include <WiFiClient.h>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic: documentation Related to documentation for the project type: enhancement Proposed improvement
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants