Skip to content

Commit

Permalink
Giga Wifi driver, based on WifiNINA driver
Browse files Browse the repository at this point in the history
  • Loading branch information
pmantoine committed Nov 1, 2023
1 parent d0759e9 commit d46a6f0
Show file tree
Hide file tree
Showing 6 changed files with 428 additions and 1 deletion.
8 changes: 8 additions & 0 deletions CommandStation-EX.ino
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,11 @@ void setup()
// Start Ethernet if it exists
#ifndef ARDUINO_ARCH_ESP32
#if WIFI_ON
#ifndef WIFI_NINA
WifiInterface::setup(WIFI_SERIAL_LINK_SPEED, F(WIFI_SSID), F(WIFI_PASSWORD), F(WIFI_HOSTNAME), IP_PORT, WIFI_CHANNEL, WIFI_FORCE_AP);
#else
WifiNINA::setup(WIFI_SSID, WIFI_PASSWORD, WIFI_HOSTNAME, IP_PORT, WIFI_CHANNEL, WIFI_FORCE_AP);
#endif // WIFI_NINA
#endif // WIFI_ON
#else
// ESP32 needs wifi on always
Expand Down Expand Up @@ -144,7 +148,11 @@ void loop()
// Responsibility 3: Optionally handle any incoming WiFi traffic
#ifndef ARDUINO_ARCH_ESP32
#if WIFI_ON
#ifndef WIFI_NINA
WifiInterface::loop();
#else
WifiNINA::loop();
#endif //WIFI_NINA
#endif //WIFI_ON
#else //ARDUINO_ARCH_ESP32
#ifndef WIFI_TASK_ON_CORE0
Expand Down
6 changes: 6 additions & 0 deletions DCCEX.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
/*
* © 2023 Paul M. Antoine
* © 2021 Fred Decker
* © 2020-2021 Harald Barth
* © 2020-2021 Chris Harlow
Expand Down Expand Up @@ -33,8 +34,13 @@
#include "SerialManager.h"
#include "version.h"
#ifndef ARDUINO_ARCH_ESP32
#ifdef WIFI_NINA
#include "Wifi_NINA.h"
#else
#include "WifiInterface.h"
#endif // WIFI_NINA
#else
#undef WIFI_NINA
#include "WifiESP32.h"
#endif
#if ETHERNET_ON == true
Expand Down
Loading

0 comments on commit d46a6f0

Please sign in to comment.