8000 Added RP2040-Eins board (#1804) · erpebe/arduino-pico@3ce9021 · GitHub
[go: up one dir, main page]

Skip to content

Commit 3ce9021

Browse files
authored
Added RP2040-Eins board (earlephilhower#1804)
* Aggregated several earlier patches in one to add RP2040-Eins board into the project. - Moved RP2040-ProMini in alphabetical order position. - Added board description files for RP2040-Eins. - Added board header file for RP2040-Eins. - Adjusted unused pins order of RP2040-ProMini to be the same as in RP2040-Eins. - Added RP2040-Eins to README.md. - Renamed board files to use underscores to better fit the existing file naming style. * Updated README.md
1 parent c34e602 commit 3ce9021

File tree

8 files changed

+761
-305
lines changed

8 files changed

+761
-305
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,8 @@ Read the [Contributing Guide](https://github.com/earlephilhower/arduino-pico/blo
5353
* Pimoroni Plasma2040
5454
* Pimoroni Tiny2040
5555
* RAKwireless RAK11300
56+
* Redscorp RP2040-Eins
57+
* Redscorp RP2040-ProMini
5658
* Sea-Picro
5759
* Seeed Indicator RP2040
5860
* Seeed XIAO RP2040
@@ -71,7 +73,6 @@ Read the [Contributing Guide](https://github.com/earlephilhower/arduino-pico/blo
7173
* WIZnet W5100S-EVB-Pico
7274
* WIZnet W5500-EVB-Pico
7375
* WIZnet WizFi360-EVB-Pico
74-
* Redscorp RP2040-ProMini
7576
* Generic (configurable flash, I/O pins)
7677

7778
# Installing via Arduino Boards Manager

boards.txt

Lines changed: 580 additions & 290 deletions
Large diffs are not rendered by default.

package/package_pico_index.template.json

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,12 @@
158158
{
159159
"name": "RAKwireless RAK11300"
160160
},
161+
{
162+
"name": "redscorp RP2040-Eins"
163+
},
164+
{
165+
"name": "redscorp RP2040-ProMini"
166+
},
161167
{
162168
"name": "Generic Sea-Picro"
163169
},
@@ -215,9 +221,6 @@
215221
{
216222
"name": "WIZnet W5500-EVB-Pico"
217223
},
218-
{
219-
"name": "redscorp RP2040-ProMini"
220-
},
221224
{
222225
"name": "Generic RP2040"
223226
}

tools/json/redscorp_rp2040_eins.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": "boot2_w25q080_2_padded_checksum.S",
6+
"usb_vid": "0x2341",
7+
"usb_pid": "0x005F"
8+
}
9+
},
10+
"core": "earlephilhower",
11+
"cpu": "cortex-m0plus",
12+
"extra_flags": "-D ARDUINO_REDSCORP_RP2040_EINS -DARDUINO_ARCH_RP2040 -DUSBD_MAX_POWER_MA=250",
13+
"f_cpu": "133000000L",
14+
"hwids": [
15+
[
16+
"0x2E8A",
17+
"0x00C0"
18+
],
19+
[
20+
"0x2341",
21+
"0x005F"
22+
]
23+
],
24+
"mcu": "rp2040",
25+
"variant": "redscorp_rp2040_eins"
26+
},
27+
"debug": {
28+
"jlink_device": "RP2040_M0_0",
29+
"openocd_target": "rp2040.cfg",
30+
"svd_path": "rp2040.svd"
31+
},
32+
"frameworks": [
33+
"arduino"
34+
],
35+
"name": "RP2040-Eins",
36+
"upload": {
37+
"maximum_ram_size": 270336,
38+
"maximum_size": 16777216,
39+
"require_upload_port": true,
40+
"native_usb": true,
41+
"use_1200bps_touch": true,
42+
"wait_for_upload_port": false,
43+
"protocol": "picotool",
44+
"protocols": [
45+
"blackmagic",
46+
"cmsis-dap",
47+
"jlink",
48+
"raspberrypi-swd",
49+
"picotool",
50+
"picoprobe",
51+
"pico-debug"
52+
]
53+
},
54+
"url": "https://www.raspberrypi.org/products/raspberry-pi-pico/",
55+
"vendor": "redscorp"
56+
}

tools/json/redscorp-rp2040-promini.json renamed to tools/json/redscorp_rp2040_promini.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
]
2323
],
2424
"mcu": "rp2040",
25-
"variant": "redscorp-rp2040-promini"
25+
"variant": "redscorp_rp2040_promini"
2626
},
2727
"debug": {
2828
"jlink_device": "RP2040_M0_0",

tools/makeboards.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -417,6 +417,10 @@ def MakeBoardJSON(name, vendor_name, product_name, vid, pid, pwr, boarddefine, f
417417
# RAKwireless
418418
MakeBoard("rakwireless_rak11300", "RAKwireless", "RAK11300", "0x2e8a", "0x00c0", 500, "RAKWIRELESS_RAK11300", 2, "boot2_w25q16jvxq_4_padded_checksum", None, "https://store.rakwireless.com/products/wisduo-lpwan-module-rak11300")
419419

420+
# Redscorp
421+
MakeBoard("redscorp_rp2040_eins", "redscorp", "RP2040-Eins", "0x2341", ["0x005f", "0x805f", "0x015f", "0x025f"] , 250, "REDSCORP_RP2040_EINS", 16, "boot2_w25q080_2_padded_checksum")
422+
MakeBoard("redscorp_rp2040_promini", "redscorp", "RP2040-ProMini", "0x2341", ["0x005f", "0x805f", "0x015f", "0x025f"] , 250, "REDSCORP_RP2040_PROMINI", 16, "boot2_w25q080_2_padded_checksum")
423+
420424
# Sea-Picro
421425
MakeBoard("sea_picro", "Generic", "Sea-Picro", "0x2e8a", "0xf00a", 500, "SEA_PICRO", 8, "boot2_w25q64jv_4_padded_checksum", None, "https://github.com/joshajohnson/sea-picro")
422426

@@ -456,9 +460,6 @@ def MakeBoardJSON(name, vendor_name, product_name, vid, pid, pwr, boarddefine, f
456460
MakeBoard("wiznet_wizfi360_evb_pico", "WIZnet", "WizFi360-EVB-Pico", "0x2e8a", "0x1028", 250, "WIZNET_WIZFI360_EVB_PICO", 2, "boot2_w25q080_2_padded_checksum")
457461
MakeBoard("wiznet_5500_evb_pico", "WIZnet", "W5500-EVB-Pico", "0x2e8a", "0x1029", 250, "WIZNET_5500_EVB_PICO", 2, "boot2_w25q080_2_padded_checksum")
458462

459-
# AG
460-
MakeBoard("redscorp-rp2040-promini", "redscorp", "RP2040-ProMini", "0x2341", ["0x005f", "0x805f", "0x015f", "0x025f"] , 250, "REDSCORP_RP2040_PROMINI", 16, "boot2_w25q080_2_padded_checksum")
461-
462463
# Generic
463464
MakeBoard("generic", "Generic", "RP2040", "0x2e8a", "0xf00a", 250, "GENERIC_RP2040", 16, "boot2_generic_03h_4_padded_checksum")
464465

Lines changed: 105 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,105 @@
1+
/* RP2040-Eins board support
2+
URL: https://github.com/red-scorp/RP2040-Eins
3+
Based on Arduino Nano Connect configuration */
4+
5+
#pragma once
6+
7+
// Pin definitions taken from:
8+
// https://datasheets.raspberrypi.org/pico/pico-datasheet.pdf
9+
static const uint8_t D0 = (1u);
10+
static const uint8_t D1 = (0u);
11+
static const uint8_t D2 = (25u);
12+
static const uint8_t D3 = (15u);
13+
static const uint8_t D4 = (16u);
14+
static const uint8_t D5 = (17u);
15+
static const uint8_t D6 = (18u);
16+
static const uint8_t D7 = (19u);
17+
static const uint8_t D8 = (20u);
18+
static const uint8_t D9 = (21u);
19+
static const uint8_t D10 = (5u);
20+
static const uint8_t D11 = (7u);
21+
static const uint8_t D12 = (4u);
22+
static const uint8_t D13 = (6u);
23+
static const uint8_t D14 = (26u);
24+
static const uint8_t D15 = (27u);
25+
static const uint8_t D16 = (28u);
26+
static const uint8_t D17 = (29u);
27+
static const uint8_t D18 = (12u);
28+
static const uint8_t D19 = (13u);
29+
static const uint8_t D20 = (22u);
30+
static const uint8_t D21 = (23u);
31+
static const uint8_t D22 = (9u);
32+
static const uint8_t D23 = (10u);
33+
static const uint8_t D24 = (11u);
34+
static const uint8_t D25 = (8u);
35+
static const uint8_t D26 = (2u);
36+
static const uint8_t D27 = (24u);
37+
static const uint8_t D28 = (3u);
38+
static const uint8_t D29 = (14u);
39+
40+
static const uint8_t A0 = (26u);
41+
static const uint8_t A1 = (27u);
42+
static const uint8_t A2 = (28u);
43+
static const uint8_t A3 = (29u);
44+
45+
// LEDs
46+
#define PIN_LED (D13)
47+
#define PIN_LED_R (D22)
48+
#define PIN_LED_G (D23)
49+
#define PIN_LED_B (D24)
50+
#define LED_BUILTIN PIN_LED
51+
52+
// Serial
53+
#define PIN_SERIAL1_TX (D1)
54+
#define PIN_SERIAL1_RX (D0)
55+
56+
#define PIN_SERIAL2_TX (D25)
57+
#define PIN_SERIAL2_RX (D26)
58+
#define PIN_SERIAL2_CTS (D27)
59+
#define PIN_SERIAL2_RTS (D28)
60+
61+
// SPI
62+
#define PIN_SPI0_MISO (D12)
63+
#define PIN_SPI0_MOSI (D11)
64+
#define PIN_SPI0_SCK (D13)
65+
#define PIN_SPI0_SS (D10)
66+
67+
#define PIN_SPI1_MISO (D25)
68+
#define PIN_SPI1_MOSI (D28)
69+
#define PIN_SPI1_SCK (D29)
70+
#define PIN_SPI1_SS (D10)
71+
72+
// Wire
73+
#define PIN_WIRE0_SDA (D18)
74+
#define PIN_WIRE0_SCL (D19)
75+
76+
#define PIN_WIRE1_SDA (D14)
77+
#define PIN_WIRE1_SCL (D15)
78+
79+
#define SERIAL_HOWMANY (3u)
80+
#define SPI_HOWMANY (2u)
81+
#define WIRE_HOWMANY (1u)
82+
83+
#define PINS_COUNT (30u)
84+
#define NUM_DIGITAL_PINS (30u)
85+
#define NUM_ANALOG_INPUTS (4u)
86+
#define NUM_ANALOG_OUTPUTS (0u)
87+
#define ADC_RESOLUTION (12u)
88+
89+
#define DigitalPinToPinName(p) (p)
90+
91+
static const uint8_t SS = PIN_SPI0_SS;
92+
static const uint8_t MOSI = PIN_SPI0_MOSI;
93+
static const uint8_t MISO = PIN_SPI0_MISO;
94+
static const uint8_t SCK = PIN_SPI0_SCK;
95+
96+
// Some random stuff
97+
98+
#define SERIAL_PORT_USBVIRTUAL SerialUSB
99+
#define SERIAL_PORT_MONITOR SerialUSB
100+
#define SERIAL_PORT_HARDWARE Serial1
101+
#define SERIAL_PORT_HARDWARE_OPEN Serial2
102+
103+
#define CRYPTO_WIRE Wire
104+
105+
#define USB_MAX_POWER (500)

variants/redscorp-rp2040-promini/pins_arduino.h renamed to variants/redscorp_rp2040_promini/pins_arduino.h

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,13 @@ static const uint8_t D18 = (12u);
2828
static const uint8_t D19 = (13u);
2929
static const uint8_t D20 = (22u);
3030
static const uint8_t D21 = (23u);
31-
static const uint8_t D22 = (2u);
32-
static const uint8_t D23 = (24u);
33-
static const uint8_t D24 = (3u);
31+
static const uint8_t D22 = (9u);
32+
static const uint8_t D23 = (10u);
33+
static const uint8_t D24 = (11u);
3434
static const uint8_t D25 = (8u);
35-
static const uint8_t D26 = (9u);
36-
static const uint8_t D27 = (10u);
37-
static const uint8_t D28 = (11u);
35+
static const uint8_t D26 = (2u);
36+
static const uint8_t D27 = (24u);
37+
static const uint8_t D28 = (3u);
3838
static const uint8_t D29 = (14u);
3939

4040
static const uint8_t A0 = (26u);
@@ -44,6 +44,7 @@ static const uint8_t A3 = (29u);
4444

4545
// LEDs
4646
#define PIN_LED (D13)
47+
#define LED_BUILTIN PIN_LED
4748

4849
// Serial
4950
#define PIN_SERIAL1_TX (D1)
@@ -82,7 +83,6 @@ static const uint8_t A3 = (29u);
8283
#define NUM_ANALOG_OUTPUTS (0u)
8384
#define ADC_RESOLUTION (12u)
8485

85-
#define LED_BUILTIN PIN_LED
8686
#define DigitalPinToPinName(p) (p)
8787

8888
static const uint8_t SS = PIN_SPI0_SS;

0 commit comments

Comments
 (0)
0