Skip to content

Commit f124e5e

Browse files
jacobrosenthalsandeepmistry
authored andcommitted
consolidates to using .protocol instead of .interface and correct defines (sandeepmistry#114)
* consolidating custom .interface keys to more standard .protocol keys * platform.txt fix spelling * fix microbit target
1 parent 08f4e55 commit f124e5e

File tree

3 files changed

+21
-25
lines changed

3 files changed

+21
-25
lines changed

boards.txt

Lines changed: 12 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,7 @@ Blend2.vid.0=0x0204
6666
Blend2.pid.0=0x0d28
6767

6868
Blend2.upload.tool=sandeepmistry:openocd
69-
Blend2.upload.protocol=
70-
Blend2.upload.interface=cmsis-dap
69+
Blend2.upload.protocol=cmsis-dap
7170
Blend2.upload.target=nrf52
7271
Blend2.upload.maximum_size=524288
7372
Blend2.upload.setup_command=transport select swd;
@@ -106,8 +105,7 @@ BLENano2.vid.0=0x0204
106105
BLENano2.pid.0=0x0d28
107106

108107
BLENano2.upload.tool=sandeepmistry:openocd
109-
BLENano2.upload.protocol=
110-
BLENano2.upload.interface=cmsis-dap
108+
BLENano2.upload.protocol=cmsis-dap
111109
BLENano2.upload.target=nrf52
112110
BLENano2.upload.maximum_size=524288
113111
BLENano2.upload.setup_command=transport select swd;
@@ -146,8 +144,7 @@ nRF52DK.vid.0=0x1366
146144
nRF52DK.pid.0=0x1015
147145

148146
nRF52DK.upload.tool=sandeepmistry:openocd
149-
nRF52DK.upload.protocol=
150-
nRF52DK.upload.interface=jlink
147+
nRF52DK.upload.protocol=jlink
151148
nRF52DK.upload.target=nrf52
152149
nRF52DK.upload.maximum_size=524288
153150
nRF52DK.upload.setup_command=transport select swd;
@@ -268,8 +265,7 @@ BBCmicrobit.vid.0=0x0d28
268265
BBCmicrobit.pid.0=0x0204
269266

270267
BBCmicrobit.upload.tool=sandeepmistry:openocd
271-
BBCmicrobit.upload.protocol=
272-
BBCmicrobit.upload.interface=cmsis-dap
268+
BBCmicrobit.upload.protocol=cmsis-dap
273269
BBCmicrobit.upload.target=nrf51
274270
BBCmicrobit.upload.maximum_size=262144
275271
BBCmicrobit.upload.setup_command=transport select swd;
@@ -368,8 +364,7 @@ PCA1000X.build.ldscript=nrf51_xxaa.ld
368364
PCA1000X.build.lfclk_flags=-DUSE_LFXO
369365

370366
PCA1000X.upload.tool=sandeepmistry:openocd
371-
PCA1000X.upload.protocol=
372-
PCA1000X.upload.interface=jlink
367+
PCA1000X.upload.protocol=jlink
373368
PCA1000X.upload.target=nrf51
374369
PCA1000X.upload.maximum_size=262144
375370
PCA1000X.upload.setup_command=transport select swd; set WORKAREASIZE 0;
@@ -407,9 +402,10 @@ PCA1000X.menu.lfclk.lfsynt.build.lfclk_flags=-DUSE_LFSYNT
407402
nRF51Dongle.name= Nordic nRF51 Dongle (PCA10031)
408403

409404
nRF51Dongle.upload.tool=sandeepmistry:openocd
410-
nRF51Dongle.upload.interface=cmsisdap
405+
nRF51Dongle.upload.protocol=cmsis-dap
411406
nRF51Dongle.upload.target=nrf51
412407
nRF51Dongle.upload.maximum_size=262144
408+
nRF51Dongle.upload.setup_command=transport select swd;
413409

414410
nRF51Dongle.bootloader.tool=sandeepmistry:openocd
415411

@@ -445,6 +441,7 @@ nRF51Dongle.menu.softdevice.s130.upload.maximum_size=151552
445441
nRF51Dongle.menu.softdevice.s130.build.extra_flags=-DNRF51 -DS130 -DNRF51_S130
446442
nRF51Dongle.menu.softdevice.s130.build.ldscript=armgcc_s130_nrf51822_{build.chip}.ld
447443

444+
448445
OSHChip.name=OSHChip
449446

450447
OSHChip.upload.tool=sandeepmistry:openocd
@@ -486,9 +483,10 @@ OSHChip.menu.softdevice.s130.build.ldscript=armgcc_s130_nrf51822_xxac.ld
486483
BLENano.name=RedBearLab BLE Nano
487484

488485
BLENano.upload.tool=sandeepmistry:openocd
489-
BLENano.upload.interface=cmsisdap
486+
BLENano.upload.protocol=cmsis-dap
490487
BLENano.upload.target=nrf51
491488
BLENano.upload.maximum_size=262144
489+
BLENano.upload.setup_command=transport select swd;
492490

493491
BLENano.bootloader.tool=sandeepmistry:openocd
494492

@@ -530,9 +528,10 @@ BLENano.menu.softdevice.s130.build.ldscript=armgcc_s130_nrf51822_{build.chip}.ld
530528
RedBearLab_nRF51822.name=RedBearLab nRF51822
531529

532530
RedBearLab_nRF51822.upload.tool=sandeepmistry:openocd
533-
RedBearLab_nRF51822.upload.interface=cmsisdap
531+
RedBearLab_nRF51822.upload.protocol=cmsis-dap
534532
RedBearLab_nRF51822.upload.target=nrf51
535533
RedBearLab_nRF51822.upload.maximum_size=262144
534+
RedBearLab_nRF51822.upload.setup_command=transport select swd;
536535

537536
RedBearLab_nRF51822.bootloader.tool=sandeepmistry:openocd
538537

platform.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -116,16 +116,16 @@ tools.openocd.cmd.windows=bin/openocd.exe
116116

117117
tools.openocd.upload.params.verbose=-d2
118118
tools.openocd.upload.params.quiet=-d0
119-
tools.openocd.upload.pattern="{path}/{cmd}" {upload.verbose} -f interface/{upload.interface}.cfg -c "{upload.setup_command}" -f target/{upload.target}.cfg -c "program {{{build.path}/{build.project_name}.hex}} verify reset; shutdown;"
119+
tools.openocd.upload.pattern="{path}/{cmd}" {upload.verbose} -f interface/{upload.protocol}.cfg -c "{upload.setup_command}" -f target/{upload.target}.cfg -c "program {{{build.path}/{build.project_name}.hex}} verify reset; shutdown;"
120120

121121
tools.openocd.program.params.verbose=-d2
122122
tools.openocd.program.params.quiet=-d0
123-
tools.openocd.program.pattern="{path}/{cmd}" {program.verbose} -f interface/{program.interface}.cfg -c "{program.setup_command}" -f target/{upload.target}.cfg -c "program {{{build.path}/{build.project_name}.hex}} verify reset; shutdown;"
123+
tools.openocd.program.pattern="{path}/{cmd}" {program.verbose} -f interface/{program.protocol}.cfg -c "{program.setup_command}" -f target/{upload.target}.cfg -c "program {{{build.path}/{build.project_name}.hex}} verify reset; shutdown;"
124124

125125
tools.openocd.erase.params.verbose=-d3
126126
tools.openocd.erase.params.quiet=-d0
127127
tools.openocd.erase.pattern=
128128

129129
tools.openocd.bootloader.params.verbose=-d2
130130
tools.openocd.bootloader.params.quiet=-d0
131-
tools.openocd.bootloader.pattern="{path}/{cmd}" {bootloader.verbose} -f interface/{program.interface}.cfg -c "{program.setup_command}" -f target/{upload.target}.cfg -c "init; halt; nrf51 mass_erase; program {{{runtime.platform.path}/cores/nRF5/SDK/components/softdevice/{softdevice}/hex/{softdevice}_{upload.target}_{softdeviceversion}_softdevice.hex}} verify reset; shutdown;"
131+
tools.openocd.bootloader.pattern="{path}/{cmd}" {bootloader.verbose} -f interface/{program.protocol}.cfg -c "{program.setup_command}" -f target/{upload.target}.cfg -c "init; halt; nrf51 mass_erase; program {{{runtime.platform.path}/cores/nRF5/SDK/components/softdevice/{softdevice}/hex/{softdevice}_{upload.target}_{softdeviceversion}_softdevice.hex}} verify reset; shutdown;"

programmers.txt

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,20 @@
11
jlink.name=J-Link
22
jlink.communication=USB
3-
jlink.protocol=
4-
jlink.program.protocol=
3+
jlink.protocol=jlink
4+
jlink.program.protocol=jlink
55
jlink.program.tool=openocd
6-
jlink.program.interface=jlink
76
jlink.program.setup_command=transport select swd; set WORKAREASIZE 0;
87

98
stlink.name=ST-Link V2
109
stlink.communication=USB
11-
stlink.protocol=
12-
stlink.program.protocol=
10+
stlink.protocol=stlink-v2
11+
stlink.program.protocol=stlink-v2
1312
stlink.program.tool=openocd
14-
stlink.program.interface=stlink-v2
1513
stlink.program.setup_command=transport select hla_swd; set WORKAREASIZE 0x4000;
1614

1715
cmsisdap.name=CMSIS-DAP
1816
cmsisdap.communication=USB
19-
cmsisdap.protocol=
20-
cmsisdap.program.protocol=
17+
cmsisdap.protocol=cmsis-dap
18+
cmsisdap.program.protocol=cmsis-dap
2119
cmsisdap.program.tool=openocd
22-
cmsisdap.program.interface=cmsis-dap
2320
cmsisdap.program.setup_command=;

0 commit comments

Comments
 (0)