knurling-rs / probe-run

Run embedded programs just like native ones
Apache License 2.0
643 stars 75 forks source link

README.md: Replace ${PROBE_RUN_CHIP} in code example #190

Closed bobmcwhirter closed 3 years ago

bobmcwhirter commented 3 years ago

The example makes it look like using a literal ${PROBE_RUN_CHIP} in the config is viable, while it seems to not actually be.

Urhengulas commented 3 years ago

Hi @bobmcwhirter, Thank you for your PR!

What would you think about the following slightly adapted version of yours? Is it clear enough?


Add this line to your Cargo configuration file (.cargo/config) and replace ${PROBE_RUN_CHIP} with the particular --chip value:

[target.'cfg(all(target_arch = "arm", target_os = "none"))']
runner = "probe-run --chip ${PROBE_RUN_CHIP}"

For example, one would use nRF52840_xxAA for the nRF52840 microcontroller. To list all supported chips run probe-run --list-chips.

bobmcwhirter commented 3 years ago

Sure, works for me!

Urhengulas commented 3 years ago

bors r+

Urhengulas commented 3 years ago

Thank you @bobmcwhirter! 😁

bors[bot] commented 3 years ago

Build succeeded: