knurling-rs / probe-run

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

Add option to verify written flash #353

Closed suyashb95 closed 1 year ago

suyashb95 commented 1 year ago
suyashb95 commented 1 year ago

@Urhengulas I've got an ST Link JTAG programmer and an ESP32, would love some tips on testing this out!

suyashb95 commented 1 year ago

@Urhengulas I've got an ST Link JTAG programmer and an ESP32, would love some tips on testing this out!

Sure!

  1. Install your local probe-run
    $ cd path/to/probe-run
    $ cargo install --path .
  2. Set up the https://github.com/knurling-rs/app-template for your board
  3. Add the --verify option to the runner in .cargo/config.toml (link)
  4. Then just run a few of the examples, e.g.:
    $ cargo rb hello
  5. Try it in combination with some of the other configuration flags, e.g. --measure-stack, --no-flash, --connect-under-reset
  6. If that behaves as expected you can mark the PR as ready for review.

PS: Please add the change to the CHANGELOG.md.

@Urhengulas Turns out the ST Link debuggers don't work with the ESP32 https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-guides/jtag-debugging/index.html#jtag-debugging-selecting-jtag-adapter

Would it be possible to test this out on your end?

Urhengulas commented 1 year ago

bors r+

bors[bot] commented 1 year ago

Build failed:

bors[bot] commented 1 year ago

:v: Suyash458 can now approve this pull request. To approve and merge a pull request, simply reply with bors r+. More detailed instructions are available here.

suyashb95 commented 1 year ago

bors r+

bors[bot] commented 1 year ago

Build succeeded: