knurling-rs / probe-run

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

probe-rs does not support passing configuration for "--chip-description-path" argument to underlying probe-rs #291

Closed TomDeRybel closed 2 years ago

TomDeRybel commented 2 years ago

Describe the bug I'm using parts in the STM32H735 family, which recently gained PAC and HAL support. Unfortunately these parts aren't supported by probe-rs yet (no yaml file entries for them in the crate). Thus, I used the procedure indicated by probe-rs to generate a local yaml from the pack file provided by ARM. This seems to all work fine using the probe-rs tools, such as cargo-flash, which support the use of the "--chip-description-path" argument.

To allow probe-run to do the same, I would need to be able to configure the path to this self-generated yaml, which currently does not seem supported.

Expected and observed behavior I expect an argument to specify the path to the underlying probe-rs in .cargo/config, for instance: runner = "probe-run --chip STM32H723VGTx --chip-description-path ../probe-rs_generated_packs/STM32H7_Series.yaml"

Operating System: Linux

jonas-schievink commented 2 years ago

This seems like something that would potentially be better solved with an environment variable that adds search paths for chip descriptions (that way the change applies across tools)

TomDeRybel commented 2 years ago

An environment variable would work for me. At this time, the probe-rs tools use different mechanisms themselves:

TomDeRybel commented 2 years ago

Thank you for adding this feature!

Urhengulas commented 2 years ago

Thank you for adding this feature!

You should thank @KOBA789 for implementing it! 👏🏾

TomDeRybel commented 2 years ago

Thank you @KOBA789! This helps a lot with my own STM32H735 adventures :champagne: