Skip to content

Commit

Permalink
Merge branch 'release/v1.6.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
ivankravets committed Apr 1, 2022
2 parents e5579ce + 5806c57 commit fbb7cc8
Show file tree
Hide file tree
Showing 8 changed files with 26 additions and 27 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@

RP2040 is a low-cost, high-performance microcontroller device with a large on-chip memory, symmetric dual-core processor complex, deterministic bus fabric, and rich peripheral set augmented with a unique Programmable I/O (PIO) subsystem, it provides professional users with unrivalled power and flexibility.

* [Home](http://platformio.org/platforms/raspberrypi) (home page in PlatformIO Platform Registry)
* [Documentation](http://docs.platformio.org/page/platforms/raspberrypi.html) (advanced usage, packages, boards, frameworks, etc.)
* [Home](https://registry.platformio.org/platforms/platformio/raspberrypi) (home page in the PlatformIO Registry)
* [Documentation](https://docs.platformio.org/page/platforms/raspberrypi.html) (advanced usage, packages, boards, frameworks, etc.)

# Usage

1. [Install PlatformIO](http://platformio.org)
2. Create PlatformIO project and configure a platform option in [platformio.ini](http://docs.platformio.org/page/projectconf.html) file:
2. Create PlatformIO project and configure a platform option in [platformio.ini](https://docs.platformio.org/page/projectconf.html) file:

## Stable version

Expand All @@ -32,4 +32,4 @@ board = ...

# Configuration

Please navigate to [documentation](http://docs.platformio.org/page/platforms/raspberrypi.html).
Please navigate to [documentation](https://docs.platformio.org/page/platforms/raspberrypi.html).
2 changes: 2 additions & 0 deletions builder/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,8 @@ def _jlink_cmd_script(env, source):
UPLOADER="openocd",
UPLOADERFLAGS=openocd_args,
UPLOADCMD="$UPLOADER $UPLOADERFLAGS")
if not board.get("upload").get("offset_address"):
upload_source = target_elf
upload_actions = [env.VerboseAction("$UPLOADCMD", "Uploading $SOURCE")]

# custom upload tool
Expand Down
2 changes: 1 addition & 1 deletion examples/arduino-blink/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
How to build PlatformIO based project
=====================================

1. [Install PlatformIO Core](http://docs.platformio.org/page/core.html)
1. [Install PlatformIO Core](https://docs.platformio.org/page/core.html)
2. Download [development platform with examples](https://github.com/platformio/platform-raspberrypi/archive/develop.zip)
3. Extract ZIP archive
4. Run these commands:
Expand Down
2 changes: 1 addition & 1 deletion examples/arduino-blink/platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
; Library options: dependencies, extra library storages
;
; Please visit documentation for the other options and examples
; http://docs.platformio.org/page/projectconf.html
; https://docs.platformio.org/page/projectconf.html

[env]
platform = raspberrypi
Expand Down
2 changes: 1 addition & 1 deletion examples/arduino-external-libs/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
How to build PlatformIO based project
=====================================

1. [Install PlatformIO Core](http://docs.platformio.org/page/core.html)
1. [Install PlatformIO Core](https://docs.platformio.org/page/core.html)
2. Download [development platform with examples](https://github.com/platformio/platform-raspberrypi/archive/develop.zip)
3. Extract ZIP archive
4. Run these commands:
Expand Down
2 changes: 1 addition & 1 deletion examples/arduino-external-libs/platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
; Library options: dependencies, extra library storages
;
; Please visit documentation for the other options and examples
; http://docs.platformio.org/page/projectconf.html
; https://docs.platformio.org/page/projectconf.html

[env]
platform = raspberrypi
Expand Down
6 changes: 3 additions & 3 deletions platform.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "raspberrypi",
"title": "Raspberry Pi RP2040",
"description": "RP2040 is a low-cost, high-performance microcontroller device with with a large on-chip memory, symmetric dual-core processor complex, and rich peripheral.",
"description": "RP2040 is a low-cost, high-performance microcontroller device with a large on-chip memory, symmetric dual-core processor complex, and rich peripheral.",
"homepage": "https://www.raspberrypi.org/documentation/rp2040/getting-started/",
"license": "Apache-2.0",
"keywords": [
Expand All @@ -18,7 +18,7 @@
"type": "git",
"url": "https://github.com/platformio/platform-raspberrypi.git"
},
"version": "1.5.0",
"version": "1.6.0",
"frameworks": {
"arduino": {
"package": "framework-arduino-mbed",
Expand All @@ -35,7 +35,7 @@
"type": "framework",
"optional": true,
"owner": "platformio",
"version": "~2.6.0"
"version": "~3.0.1"
},
"tool-rp2040tools": {
"type": "uploader",
Expand Down
29 changes: 13 additions & 16 deletions platform.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,19 +100,16 @@ def _add_default_debug_tools(self, board):
board.manifest["debug"] = debug
return board

def configure_debug_options(self, initial_debug_options, ide_data):
debug_options = copy.deepcopy(initial_debug_options)
adapter_speed = initial_debug_options.get("speed", "5000")
if adapter_speed:
server_options = debug_options.get("server") or {}
server_executable = server_options.get("executable", "").lower()
if "target/cmsis-dap.cfg" in server_options.get("arguments", []):
debug_options["server"]["arguments"].extend(
["-c", "adapter_khz %s" % adapter_speed]
)
elif "jlink" in server_executable:
debug_options["server"]["arguments"].extend(
["-speed", adapter_speed]
)

return debug_options
def configure_debug_session(self, debug_config):
adapter_speed = debug_config.speed or "5000"

server_options = debug_config.server or {}
server_arguments = server_options.get("arguments", [])
if "interface/cmsis-dap.cfg" in server_arguments:
server_arguments.extend(
["-c", "adapter speed %s" % adapter_speed]
)
elif "jlink" in server_options.get("executable", "").lower():
server_arguments.extend(
["-speed", adapter_speed]
)

0 comments on commit fbb7cc8

Please sign in to comment.