Skip to content

Commit 8f49075

Browse files
authored
Arduino OPTA support (#678)
Resolves #676
1 parent 50f1d3e commit 8f49075

File tree

4 files changed

+54
-3
lines changed

4 files changed

+54
-3
lines changed

boards/opta.json

+51
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
{
2+
"build": {
3+
"arduino": {
4+
"ldscript": "linker_script.ld",
5+
"flash_layout": "50_50"
6+
},
7+
"extra_flags": "-DARDUINO_OPTA",
8+
"core": "arduino",
9+
"cpu": "cortex-m7",
10+
"f_cpu": "480000000L",
11+
"mcu": "stm32h747xih6",
12+
"variant": "OPTA",
13+
"product_line": "STM32H747xx",
14+
"hwids": [
15+
[
16+
"0x2341",
17+
"0x0364"
18+
]
19+
]
20+
},
21+
"connectivity": [
22+
"bluetooth",
23+
"wifi"
24+
],
25+
"debug": {
26+
"jlink_device": "STM32H747XI_M7",
27+
"openocd_target": "stm32h7x_dual_bank"
28+
},
29+
"frameworks": [
30+
"arduino"
31+
],
32+
"name": "Arduino Opta",
33+
"upload": {
34+
"maximum_ram_size": 523624,
35+
"maximum_size": 786432,
36+
"protocol": "dfu",
37+
"protocols": [
38+
"cmsis-dap",
39+
"dfu",
40+
"jlink",
41+
"stlink",
42+
"mbed"
43+
],
44+
"require_upload_port": true,
45+
"use_1200bps_touch": true,
46+
"wait_for_upload_port": true,
47+
"offset_address": "0x08040000"
48+
},
49+
"url": "https://www.arduino.cc/pro/hardware-arduino-opta",
50+
"vendor": "Arduino"
51+
}

builder/main.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ def _jlink_cmd_script(env, source):
220220
upload_actions = [env.VerboseAction("$UPLOADCMD", "Uploading $SOURCE")]
221221

222222
if "arduino" in frameworks:
223-
if env.subst("$BOARD").startswith("portenta"):
223+
if env.subst("$BOARD").startswith(("portenta", "opta")):
224224
upload_actions.insert(
225225
0,
226226
env.VerboseAction(BeforeUpload, "Looking for upload port...")

platform.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@
216216
"type": "framework",
217217
"optional": true,
218218
"owner": "platformio",
219-
"version": "~3.1.1"
219+
"version": "~3.5.4"
220220
},
221221
"framework-stm32cubef0": {
222222
"type": "framework",

platform.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def configure_default_packages(self, variables, targets):
3232

3333
frameworks = variables.get("pioframework", [])
3434
if "arduino" in frameworks:
35-
if board.startswith("portenta"):
35+
if board.startswith(("portenta", "opta")):
3636
self.frameworks["arduino"]["package"] = "framework-arduino-mbed"
3737
self.frameworks["arduino"][
3838
"script"

0 commit comments

Comments
 (0)