Regression: "target was not halted as expected..." - for pyocd 0.36 versions
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 1.5k
- Forks
- 560
- Avg merge
- 1h 41m
- Merged PRs (30d)
- 3
Description
I've recently noticed some issues with 0.36 release (also the 0.36-dev) series. Reverting to an earlier version of pyocd (in this case, 0.35-dev), and everything flashes (and functions) as expected.
[the pyocd.yaml file specifies the .pack to use, I'm using the one from https://github.com/IOsetting/hk32f030m-template/tree/main/Misc]
Also see https://github.com/pyocd/pyOCD/issues/1646
~/Embedded/HK32F030M-base/Projects/blink$ python3 -m pipx install git+https://github.com/pyocd/pyOCD.git
installed package pyocd 0.36.1.dev2, installed using Python 3.11.9
These apps are now globally available
- pyocd
- pyocd-gdbserver
done! ✨ 🌟 ✨
~/Embedded/HK32F030M-base/Projects/blink$ make flash
pyocd erase -c -t hk32f030mf4p6 --config ./Misc/pyocd.yaml
0001218 I Erasing chip... [eraser]
0001580 I Chip erase complete [eraser]
pyocd load ./Build/blink.hex -t hk32f030mf4p6 --config ./Misc/pyocd.yaml
0001203 I Loading /home/bdroy/Embedded/HK32F030M-base/Projects/blink/Build/blink.hex [load_cmd]
0001339 W T bit in XPSR is invalid; the vector table may be invalid or corrupt [cortex_m]
0001417 C target was not halted as expected after calling flash algorithm routine (IPSR=3) [__main__]
make: *** [rules.mk:117: flash] Error 1
~/Embedded/HK32F030M-base/Projects/blink$ pipx uninstall pyocd
uninstalled pyocd! ✨ 🌟 ✨
bdroy@bigfart:~/Embedded/HK32F030M-base/Projects/blink$ python3 -m pipx install git+https://github.com/pyocd/pyOCD.git@develop
installed package pyocd 0.35.2.dev28, installed using Python 3.11.9
These apps are now globally available
- pyocd
- pyocd-gdbserver
done! ✨ 🌟 ✨
~/Embedded/HK32F030M-base/Projects/blink$ make flash
pyocd erase -c -t hk32f030mf4p6 --config ./Misc/pyocd.yaml
0001192 I Erasing chip... [eraser]
0001559 I Chip erase complete [eraser]
pyocd load ./Build/blink.hex -t hk32f030mf4p6 --config ./Misc/pyocd.yaml
0001213 I Loading /home/bdroy/Embedded/HK32F030M-base/Projects/blink/Build/blink.hex [load_cmd]
[==================================================] 100%
0004799 I Erased 1920 bytes (15 sectors), programmed 1920 bytes (15 pages), skipped 0 bytes (0 pages) at 0.52 kB/s [loader]
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the failure with pyOCD 0.36-dev or 0.36.1.dev2 using the referenced pyocd.yaml and .pack file, then compare it with 0.35-dev. Review the related issue 1646 and the flash output, especially the invalid XPSR and halt failure. Done means the HK32F030MF4P6 image flashes successfully under the affected 0.36 series.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- embedded-iot
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100