Skip to content

Commit 8fd7c60

Browse files
authored
Add WeAct RP2350B Core board support. (#2570)
* Add WeAct RP2350B Core board support. * Update to new format.
1 parent c7f37fc commit 8fd7c60

File tree

1 file changed

+91
-0
lines changed

1 file changed

+91
-0
lines changed
Lines changed: 91 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,91 @@
1+
/*
2+
* Copyright (c) 2020 Raspberry Pi (Trading) Ltd.
3+
*
4+
* SPDX-License-Identifier: BSD-3-Clause
5+
*/
6+
7+
// -----------------------------------------------------
8+
// NOTE: THIS HEADER IS ALSO INCLUDED BY ASSEMBLER SO
9+
// SHOULD ONLY CONSIST OF PREPROCESSOR DIRECTIVES
10+
// -----------------------------------------------------
11+
12+
// This header may be included by other board headers as "boards/weact_studio_rp2350b_core.h"
13+
14+
#ifndef _BOARDS_WEACT_STUDIO_RP2350B_CORE_H
15+
#define _BOARDS_WEACT_STUDIO_RP2350B_CORE_H
16+
17+
pico_board_cmake_set(PICO_PLATFORM, rp2350)
18+
19+
// For board detection
20+
#define WEACT_STUDIO_RP2350B_CORE
21+
22+
// --- BOARD SPECIFIC ---
23+
#define WEACT_STUDIO_RP2350B_USER_SW_PIN 23
24+
#define WEACT_STUDIO_RP2350B_PSRAM_CS_PIN 0
25+
26+
// --- UART ---
27+
#ifndef PICO_DEFAULT_UART
28+
#define PICO_DEFAULT_UART 0
29+
#endif
30+
#ifndef PICO_DEFAULT_UART_TX_PIN
31+
#define PICO_DEFAULT_UART_TX_PIN 12
32+
#endif
33+
#ifndef PICO_DEFAULT_UART_RX_PIN
34+
#define PICO_DEFAULT_UART_RX_PIN 13
35+
#endif
36+
37+
// --- LED ---
38+
#ifndef PICO_DEFAULT_LED_PIN
39+
#define PICO_DEFAULT_LED_PIN 25
40+
#endif
41+
42+
// --- I2C ---
43+
#ifndef PICO_DEFAULT_I2C
44+
#define PICO_DEFAULT_I2C 0
45+
#endif
46+
#ifndef PICO_DEFAULT_I2C_SDA_PIN
47+
#define PICO_DEFAULT_I2C_SDA_PIN 8
48+
#endif
49+
#ifndef PICO_DEFAULT_I2C_SCL_PIN
50+
#define PICO_DEFAULT_I2C_SCL_PIN 9
51+
#endif
52+
53+
// --- SPI ---
54+
#ifndef PICO_DEFAULT_SPI
55+
#define PICO_DEFAULT_SPI 0
56+
#endif
57+
#ifndef PICO_DEFAULT_SPI_SCK_PIN
58+
#define PICO_DEFAULT_SPI_SCK_PIN 18
59+
#endif
60+
#ifndef PICO_DEFAULT_SPI_TX_PIN
61+
#define PICO_DEFAULT_SPI_TX_PIN 19
62+
#endif
63+
#ifndef PICO_DEFAULT_SPI_RX_PIN
64+
#define PICO_DEFAULT_SPI_RX_PIN 16
65+
#endif
66+
#ifndef PICO_DEFAULT_SPI_CSN_PIN
67+
#define PICO_DEFAULT_SPI_CSN_PIN 17
68+
#endif
69+
70+
// --- FLASH ---
71+
#define PICO_BOOT_STAGE2_CHOOSE_W25Q080 1
72+
73+
#ifndef PICO_FLASH_SPI_CLKDIV
74+
#define PICO_FLASH_SPI_CLKDIV 2
75+
#endif
76+
77+
pico_board_cmake_set_default(PICO_FLASH_SIZE_BYTES, (16 * 1024 * 1024))
78+
#ifndef PICO_FLASH_SIZE_BYTES
79+
#define PICO_FLASH_SIZE_BYTES (16 * 1024 * 1024)
80+
#endif
81+
82+
// --- RP2350 VARIANT ---
83+
// This means RP2350B.
84+
#define PICO_RP2350A 0
85+
86+
pico_board_cmake_set_default(PICO_RP2350_A2_SUPPORTED, 1)
87+
#ifndef PICO_RP2350_A2_SUPPORTED
88+
#define PICO_RP2350_A2_SUPPORTED 1
89+
#endif
90+
91+
#endif

0 commit comments

Comments
 (0)