|
24 | 24 | * [Manual Install](#manual-install)
|
25 | 25 | * [VS Code & PlatformIO](#vs-code--platformio)
|
26 | 26 | * [Packages' Patches](#packages-patches)
|
27 |
| - * [1. For RP2040-based boards](#1-for-rp2040-based-boards) |
| 27 | + * [1. For RP2040-based boards using Earle Philhower arduino-pico core](#1-for-rp2040-based-boards-using-earle-philhower-arduino-pico-core) |
| 28 | + * [1.1. To use BOARD_NAME](#11-to-use-board_name) |
| 29 | + * [1.2. To avoid compile error relating to microsecondsToClockCycles](#12-to-avoid-compile-error-relating-to-microsecondstoclockcycles) |
28 | 30 | * [HOWTO Fix `Multiple Definitions` Linker Error](#howto-fix-multiple-definitions-linker-error)
|
29 | 31 | * [More useful Information](#more-useful-information)
|
30 | 32 | * [Usage](#usage)
|
@@ -135,7 +137,7 @@ The catch is **your function is now part of an ISR (Interrupt Service Routine),
|
135 | 137 | ## Prerequisites
|
136 | 138 |
|
137 | 139 | 1. [`Arduino IDE 1.8.13+` for Arduino](https://www.arduino.cc/en/Main/Software)
|
138 |
| -2. [`Earle Philhower's arduino-pico core v1.2.1+`](https://github.com/earlephilhower/arduino-pico) for RP2040-based boards such as **RASPBERRY_PI_PICO, ADAFRUIT_FEATHER_RP2040 and GENERIC_RP2040**, etc. [](https://github.com/earlephilhower/arduino-pico/releases/latest) |
| 140 | +2. [`Earle Philhower's arduino-pico core v1.4.0+`](https://github.com/earlephilhower/arduino-pico) for RP2040-based boards such as **RASPBERRY_PI_PICO, ADAFRUIT_FEATHER_RP2040 and GENERIC_RP2040**, etc. [](https://github.com/earlephilhower/arduino-pico/releases/latest) |
139 | 141 |
|
140 | 142 | ---
|
141 | 143 | ---
|
@@ -169,19 +171,38 @@ Another way to install is to:
|
169 | 171 |
|
170 | 172 | ### Packages' Patches
|
171 | 173 |
|
172 |
| -#### 1. For RP2040-based boards |
173 |
| - |
174 |
| - ***To be able to automatically detect and display BOARD_NAME on RP2040-based boards (RASPBERRY_PI_PICO, ADAFRUIT_FEATHER_RP2040, GENERIC_RP2040, etc) boards***, you have to copy the file [RP2040 platform.txt](Packages_Patches/rp2040/hardware/rp2040/1.2.1) into rp2040 directory (~/.arduino15/packages/rp2040/hardware/rp2040/1.2.1). |
| 174 | +#### 1. For RP2040-based boards using [Earle Philhower arduino-pico core](https://github.com/earlephilhower/arduino-pico) |
175 | 175 |
|
176 |
| -Supposing the rp2040 core version is 1.2.1. This file must be copied into the directory: |
| 176 | +#### 1.1 To use BOARD_NAME |
177 | 177 |
|
178 |
| -- `~/.arduino15/packages/rp2040/hardware/rp2040/1.2.1/platform.txt` |
| 178 | + **To be able to automatically detect and display BOARD_NAME on RP2040-based boards (RASPBERRY_PI_PICO, ADAFRUIT_FEATHER_RP2040, GENERIC_RP2040, etc) boards**, you have to copy the file [RP2040 platform.txt](Packages_Patches/rp2040/hardware/rp2040/1.4.0) into rp2040 directory (~/.arduino15/packages/rp2040/hardware/rp2040/1.4.0). |
| 179 | + |
| 180 | +Supposing the rp2040 core version is 1.4.0. This file must be copied into the directory: |
| 181 | + |
| 182 | +- `~/.arduino15/packages/rp2040/hardware/rp2040/1.4.0/platform.txt` |
179 | 183 |
|
180 | 184 | Whenever a new version is installed, remember to copy this file into the new version directory. For example, new version is x.yy.zz
|
181 | 185 | This file must be copied into the directory:
|
182 | 186 |
|
183 | 187 | - `~/.arduino15/packages/rp2040/hardware/rp2040/x.yy.zz/platform.txt`
|
184 | 188 |
|
| 189 | +With core after v1.4.0, this step is not necessary anymore thanks to the PR [Add -DBOARD_NAME="{build.board}" #136](https://github.com/earlephilhower/arduino-pico/pull/136). |
| 190 | + |
| 191 | +#### 1.2 To avoid compile error relating to microsecondsToClockCycles |
| 192 | + |
| 193 | +Some libraries, such as [Adafruit DHT-sensor-library](https://github.com/adafruit/DHT-sensor-library), require the definition of microsecondsToClockCycles(). **To be able to compile and run on RP2040-based boards**, you have to copy the files in [**RP2040 Arduino.h**](Packages_Patches/rp2040/hardware/rp2040/1.4.0/cores/rp2040/Arduino.h) into rp2040 directory (~/.arduino15/packages/rp2040/hardware/rp2040/1.4.0). |
| 194 | + |
| 195 | +Supposing the rp2040 core version is 1.4.0. This file must be copied to replace: |
| 196 | + |
| 197 | +- `~/.arduino15/packages/rp2040/hardware/rp2040/1.4.0/cores/rp2040/Arduino.h` |
| 198 | + |
| 199 | +Whenever a new version is installed, remember to copy this file into the new version directory. For example, new version is x.yy.zz |
| 200 | +This file must be copied to replace: |
| 201 | + |
| 202 | +- `~/.arduino15/packages/rp2040/hardware/rp2040/x.yy.zz/cores/rp2040/Arduino.h` |
| 203 | + |
| 204 | +With core after v1.4.0, this step is not necessary anymore thanks to the PR [Add defs for compatibility #142](https://github.com/earlephilhower/arduino-pico/pull/142). |
| 205 | + |
185 | 206 | ---
|
186 | 207 | ---
|
187 | 208 |
|
|
0 commit comments