Skip to content

Commit 327f10c

Browse files
authored
Add Waveshare RP2350 Plus (#3000)
* Add Waveshare RP2350 Plus * Refactor to use flash size menu Replaces separate board entries for Waveshare RP2350 Plus 4MB and 16MB variants with a flash size menu.
1 parent a7380a5 commit 327f10c

File tree

6 files changed

+448
-1
lines changed

6 files changed

+448
-1
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,7 @@ Read the [Contributing Guide](https://github.com/earlephilhower/arduino-pico/blo
115115
* Waveshare RP2040 LCD 1.28
116116
* Waveshare RP2040 Matrix
117117
* Waveshare RP2040 PiZero
118+
* Waveshare RP2350 Plus
118119
* Waveshare RP2350 LCD 0.96
119120
* WIZnet W5100S-EVB-Pico
120121
* WIZnet W5100S-EVB-Pico2

boards.txt

Lines changed: 310 additions & 0 deletions
Large diffs are not rendered by default.

package/package_pico_index.template.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -374,6 +374,9 @@
374374
{
375375
"name": "Waveshare RP2040 LCD 1.28"
376376
},
377+
{
378+
"name": "Waveshare RP2350 Plus"
379+
},
377380
{
378381
"name": "Waveshare RP2350 LCD 0.96"
379382
},

tools/json/waveshare_rp2350_plus.json

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
{
2+
"build": {
3+
"arduino": {
4+
"earlephilhower": {
5+
"boot2_source": "none.S",
6+
"usb_vid": "0x2E8A",
7+
"usb_pid": "0x10B1"
8+
}
9+
},
10+
"core": "earlephilhower",
11+
"cpu": "cortex-m33",
12+
"extra_flags": "-DARDUINO_WAVESHARE_RP2350_PLUS -DARDUINO_ARCH_RP2040 -DUSBD_MAX_POWER_MA=500 ",
13+
"f_cpu": "150000000L",
14+
"hwids": [
15+
[
16+
"0x2E8A",
17+
"0x00C0"
18+
],
19+
[
20+
"0x2E8A",
21+
"0x10B1"
22+
]
23+
],
24+
"mcu": "rp2350",
25+
"variant": "waveshare_rp2350_plus"
26+
},
27+
"debug": {
28+
"jlink_device": "RP2350_0",
29+
"openocd_target": "rp2350.cfg",
30+
"svd_path": "rp2350.svd"
31+
},
32+
"frameworks": [
33+
"arduino",
34+
"picosdk"
35+
],
36+
"name": "RP2350 Plus",
37+
"upload": {
38+
"maximum_ram_size": 524288,
39+
"maximum_size": 4194304,
40+
"require_upload_port": true,
41+
"native_usb": true,
42+
"use_1200bps_touch": true,
43+
"wait_for_upload_port": false,
44+
"protocol": "picotool",
45+
"protocols": [
46+
"blackmagic",
47+
"cmsis-dap",
48+
"jlink",
49+
"raspberrypi-swd",
50+
"picotool",
51+
"picoprobe"
52+
]
53+
},
54+
"url": "https://www.raspberrypi.org/products/raspberry-pi-pico/",
55+
"vendor": "Waveshare"
56+
}

tools/makeboards.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -327,7 +327,7 @@ def MakeBoard(name, chip, vendor_name, product_name, vid, pid, pwr, boarddefine,
327327
tup = "riscv32-unknown-elf"
328328
opts = "-march=rv32imac_zicsr_zifencei_zba_zbb_zbs_zbkb -mabi=ilp32"
329329
else:
330-
raise Exception("Unknown board type " + str(chip));
330+
raise Exception("Unknown board type " + str(chip))
331331
BuildHeader(name, chip, tup, opts, vendor_name, product_name, vid, pid, pwr, boarddefine, name, flashsizemb * 1024 * 1024, psramsize, boot2, extra)
332332
if (name == "generic") or (name == "generic_rp2350") or (name == "vccgnd_yd_rp2040"):
333333
smfs = [ 0, 64 * 1024, 128 * 1024, 256 * 1024, 512 * 1024 ]
@@ -350,6 +350,9 @@ def MakeBoard(name, chip, vendor_name, product_name, vid, pid, pwr, boarddefine,
350350
BuildCountry(name)
351351
BuildFlashMenu(name, chip, 8*1024*1024, [0, 7*1024*1024, 4*1024*1024, 2*1024*1024])
352352
BuildFlashMenu(name, chip, 16*1024*1024, [0, 15*1024*1024, 14*1024*1024, 12*1024*1024, 8*1024*1024, 4*1024*1024, 2*1024*1024])
353+
elif name == "waveshare_rp2350_plus":
354+
BuildFlashMenu(name, chip, 4*1024*1024, [*smallfs, 1024*1024, 2*1024*1024, 3*1024*1024])
355+
BuildFlashMenu(name, chip, 16*1024*1024, [0, 15*1024*1024, 14*1024*1024, 12*1024*1024, 8*1024*1024, 4*1024*1024, 2*1024*1024])
353356
else:
354357
BuildFlashMenu(name, chip, flashsizemb * 1024 * 1024, fssizelist)
355358
if (chip == "rp2350") or (chip == "rp2350-riscv"):
@@ -693,6 +696,7 @@ def MakeBoardJSON(name, chip, vendor_name, product_name, vid, pid, pwr, boarddef
693696
MakeBoard("waveshare_rp2040_plus_16mb", "rp2040", "Waveshare", "RP2040 Plus 16MB", "0x2e8a", "0x1020", 500, "WAVESHARE_RP2040_PLUS", 16, 0, "boot2_w25q080_2_padded_checksum")
694697
MakeBoard("waveshare_rp2040_lcd_0_96", "rp2040", "Waveshare", "RP2040 LCD 0.96", "0x2e8a", "0x1021", 500, "WAVESHARE_RP2040_LCD_0_96", 2, 0, "boot2_w25q16jvxq_4_padded_checksum")
695698
MakeBoard("waveshare_rp2040_lcd_1_28", "rp2040", "Waveshare", "RP2040 LCD 1.28", "0x2e8a", "0x1039", 500, "WAVESHARE_RP2040_LCD_1_28", 2, 0, "boot2_w25q16jvxq_4_padded_checksum")
699+
MakeBoard("waveshare_rp2350_plus", "rp2350", "Waveshare", "RP2350 Plus", "0x2e8a", "0x10B1", 500, "WAVESHARE_RP2350_PLUS", 4, 0, "none")
696700
MakeBoard("waveshare_rp2350_lcd_0_96", "rp2350", "Waveshare", "RP2350 LCD 0.96", "0x2e8a", "0x10B7", 500, "WAVESHARE_RP2350_LCD_0_96", 4, 0, "none")
697701

698702
# WIZnet
Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
#pragma once
2+
3+
// Waveshare RP2350 Plus
4+
// https://www.waveshare.com/wiki/RP2350-Plus
5+
// https://files.waveshare.com/wiki/RP2350-Plus/RP2350_Plus.pdf
6+
// https://www.waveshare.com/w/upload/3/3c/680px-RP2350-Plus-details-inter.jpg
7+
//
8+
9+
/*
10+
Pin# Pin#
11+
___(_____)___
12+
GPIO0 1 | *USB C* | 40 VBUS
13+
GPIO1 2 | | 39 VSYS
14+
GND 3 | | 38 GND
15+
GPIO2 4 | | 37 3V3_EN
16+
GPIO3 5 | | 36 3V3(OUT)
17+
GPIO4 6 | | 35 ADC_VREF
18+
GPIO5 7 | | 34 GPIO28
19+
GND 8 | | 33 GND
20+
GPIO6 9 | | 32 GPIO27
21+
GPIO7 10 | | 31 GPIO26
22+
GPIO8 11 | | 30 RUN
23+
GPIO9 12 | | 29 GPIO22
24+
GND 13 | | 28 GND
25+
GPIO10 14 | | 27 GPIO21
26+
GPIO11 15 | | 25 GPIO20
27+
GPIO12 16 | | 25 GPIO19
28+
GPIO13 17 | | 24 GPIO18
29+
GND 18 | | 23 GND
30+
GPIO14 19 | | 22 GPIO17
31+
GPIO15 20 |____|_|_|____| 21 GPIO16
32+
S G S
33+
W N W
34+
C D D
35+
L I
36+
K N
37+
*/
38+
39+
#define PICO_RP2350A 1
40+
41+
// LEDs
42+
#define PIN_LED (25u)
43+
44+
// Serial
45+
#define PIN_SERIAL1_TX (0u)
46+
#define PIN_SERIAL1_RX (1u)
47+
48+
#define PIN_SERIAL2_TX (8u)
49+
#define PIN_SERIAL2_RX (9u)
50+
51+
// SPI
52+
#define PIN_SPI0_MISO (16u)
53+
#define PIN_SPI0_MOSI (19u)
54+
#define PIN_SPI0_SCK (18u)
55+
#define PIN_SPI0_SS (17u)
56+
57+
#define PIN_SPI1_MISO (12u)
58+
#define PIN_SPI1_MOSI (15u)
59+
#define PIN_SPI1_SCK (14u)
60+
#define PIN_SPI1_SS (13u)
61+
62+
// Wire
63+
#define PIN_WIRE0_SDA (8u)
64+
#define PIN_WIRE0_SCL (9u)
65+
66+
#define PIN_WIRE1_SDA (6u)
67+
#define PIN_WIRE1_SCL (7u)
68+
69+
#define SERIAL_HOWMANY (3u)
70+
#define SPI_HOWMANY (2u)
71+
#define WIRE_HOWMANY (2u)
72+
73+
#include "../generic/common.h"

0 commit comments

Comments
 (0)