Skip to content

Commit e83529a

Browse files
authored
Merge pull request #126 from pennam/pico_w-2
Add support to Raspberry Pi Pico W
2 parents f7c9eb7 + 8e11455 commit e83529a

File tree

3 files changed

+21
-0
lines changed

3 files changed

+21
-0
lines changed

Diff for: .github/workflows/compile-examples.yml

+11
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,9 @@ jobs:
101101
- fqbn: arduino:mbed_edge:edge_control
102102
platform-name: arduino:mbed_edge
103103
artifact-name-suffix: arduino-mbed_edge-edge_control
104+
- fqbn: "rp2040:rp2040:rpipicow"
105+
platform-name: rp2040:rp2040
106+
artifact-name-suffix: rp2040-rp2040-rpipicow
104107

105108
# Make board type-specific customizations to the matrix jobs
106109
include:
@@ -181,6 +184,14 @@ jobs:
181184
source-url: https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json
182185
sketch-paths: |
183186
- examples/ConnectionHandlerDemo-Notecard
187+
- board:
188+
platform-name: rp2040:rp2040
189+
platforms: |
190+
# Install rp2040 platform via Boards Manager
191+
- name: rp2040:rp2040
192+
source-url: https://github.com/earlephilhower/arduino-pico/releases/download/global/package_rp2040_index.json
193+
sketch-paths: |
194+
- examples/ConnectionHandlerDemo-Notecard
184195
185196
steps:
186197
- uses: actions/checkout@v4

Diff for: src/ConnectionHandlerDefinitions.h

+7
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,13 @@
144144
#define NETWORK_HARDWARE_ERROR
145145
#endif
146146

147+
#if defined(ARDUINO_RASPBERRY_PI_PICO_W)
148+
#define BOARD_HAS_WIFI
149+
#define NETWORK_HARDWARE_ERROR WL_NO_SHIELD
150+
#define NETWORK_IDLE_STATUS WL_IDLE_STATUS
151+
#define NETWORK_CONNECTED WL_CONNECTED
152+
#endif
153+
147154
#endif // BOARD_HAS_NOTECARD
148155

149156
/******************************************************************************

Diff for: src/WiFiConnectionHandler.h

+3
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,9 @@
4646
#include <WiFiUdp.h>
4747
#elif defined(ARDUINO_UNOR4_WIFI)
4848
#include <WiFiS3.h>
49+
#elif defined(ARDUINO_RASPBERRY_PI_PICO_W)
50+
#include <WiFi.h>
51+
#include <WiFiUdp.h>
4952
#endif
5053

5154
#ifndef BOARD_HAS_WIFI

0 commit comments

Comments
 (0)