Pyocd

Latest version: v0.36.0

Safety actively analyzes 630217 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 5 of 11

0.27.2

Fixes

- NXP Kinetis targets: Fix additional exceptions raised if no cores were found, for instance if the device is locked. 909 (Thanks Hoohaha)
- STMicro STM32 targets: Fix target types for STM32 boards with CMSIS-Pack based target support. 915
- CMSIS-Pack targets: Fix more bugs in DFP flash region generation. 919
- Cypress PSoC64: Fix SMIF flash algorithm type for `cy8c64xx_cmX_full_flash` targets. 920 (Thanks bohdan-tymkiv)

0.27.1

Fixes

- JLink: fix regression related to locking. 911

0.27.0

New features

- Support for Arm ADIv6. This is a new version of the Arm Debug Interface used with Cortex-M55 and in some advanced platforms. Cortex-M microcontrollers are expected to slowly transition to ADIv6, but most new MCUs will continue to use ADIv5.2 for quite some time.
- Recognizing the Arm SC000, SC300, and Cortex-M35P secure cores and Cortex-M55.

Boards and targets

- Added support for new revisions of secure Cypress PSoC64 devices. (Thanks bohdan-tymkiv and Cypress.)
- Added Arm Musca-S1 board ID.
- Added board IDs for Arm MPS3 AN522 and AN540.
- Fixed vendor name for LPC55S69 target.
- LPC55S69 target supports the single-core configuration (technically LPC55S66).
- Added 'lpc55s28' built-in target.
- New STMicro STM32F767 target. (Thanks bartek-w.)
- Added Samsung s5js100 target. (Thanks vince-zeng and Samsung engineers.)
- Fixed reset and connect issues with a sleeping target for the NXP i.MX RT1052. (Thanks jhqian.)

Changes

- CMSIS-Packs: Removed the debug log message for every target loaded from a pack, which could get annoying very quickly.
- User scripts: Improved logging of errors. (Thanks bartek-w.)
- Commander: The selected MEM-AP changes when the selected core is changed with the `core` command.
- Commander: Help text is wrapped to the terminal width.
- Commander: Reading memory with a size misaligned to the read width is disallowed.
- Gdbserver: Added `--core` argument to run the gdbserver for a subset of cores.
- General: The warning about `cortex_m` target type being selected is not logged if the target type was explicitly set.
- General: Added `--probe` as an alias for `--uid` on the command line.
- General: The `--frequency` argument accepts floating point values, and allows "Hz" (case-insensitive) to follow the value in addition to the previously supported metric scale suffixes. For example, `--frequency=2.2MHz` now works as expected.
- Commander: The `set clock` command accepts the same values as the `--frequency` argument.
- J-Link: The device type passed to the J-Link driver can be specified with the `jlink.device` option. (By default, "Cortex-M4" is used. This doesn't cause any problems except a warning in the J-Link log because pyOCD uses its own target discovery rather than the J-Link's.)
- DAP: Code cleanup and some small improvements in MEM-AP initialization.
- DAP: A `GeneralMemAPTarget` class was added that provides a target object for MEM-APs without a connected core. This handles the case where a MEM-AP provides access to either the system memory bus or an isolated memory bus, independent of MEM-APs for the core(s). (Thanks bohdan-tymkiv and Cypress.)
- STLink: Banked DP registers can be accessed on recent STLink firmware (V2J32 or V3J2 and above).
- Tests: Added `concurrency_test.py` functional test.
- Tests: Improve logging in some tests. (Thanks bartek-w.)
- Tests: Add process timeout for `gdb_test.py` on Python 3. (Thanks bartek-w.)

Fixes

- DAP: Solved some long-standing concurrency issues with targets being accessed from multiple threads. Only the DAP (DP and AP) layer and below are locked. This means that the target and other high level layers are not locked. For instance, two threads attempting to set breakpoints on the same core would be unpredictable. The underlying DAP accesses and memory transfers will not fail, but the FPB component registers may get into an invalid state.
- Documentation: Corrected instructions in readme for installing from the git repo.
- CMSIS-Packs: Fixed problems creating the memory map for certain cases of multiple sector sizes in flash regions or regions belonging to individual cores.
- General: ANSI flags are always cleared after the list of available probes is printed.
- General: Memory addresses are masked to 32-bits. The most visible result of this is that you will see only a 32-bit value reported in the error if you accidentally pass a larger-width value to a read or write command (because Python intrinsically supports arbitrary-width integers).
- udev rules: Fixed line endings and remove symlink directives in the STLink udev rules included in the pyOCD repo.
- General: Resolved a deprecation warning for the `Thread.isAlive()` method from the Python `threading` module.

0.26.1

Fixes

- Fixed invalid reference to `DFSR_PMU` constant from `CortexM`.
- Fixed `read_memory_block32()` size parameter in `ElfReaderContext`. (Thanks mbrossard!)
- Address Python 3 string conversion issue in semihosting. (Thanks mbrossard!)
- Workaround for failure to init flash algo in verify mode.
- gdbserver: clear stale flash data on exception during flash programming.
- Fixed flash object creation in cases where the memory map is modified during the init sequence.
- Fixed NXP kl28z target issues. (Thanks Hoohaha!)

0.26.0

New features

- Experimental SEGGER J-Link probe support.
- Uses the J-Link driver via the `pylink-square` package, which will find the driver if installed in the standard location on all three supported OSes.
- Added `jlink.power` user option to control the J-Link's power output. Defaults to enabled.
- New `reset` subcommand.
- `pack` subcommand option `--find` prints an "Installed" column showing whether the containing CMSIS-Pack is already installed and the target is available.
- `pack` subcommand options `--find` and `--install` match the given part number pattern anywhere within the part number (contains match).
- Commander improvements:
- `st` alias for `status`.
- Results from Python expressions are pretty printed.
- `show locked` prints whether the target is locked (for NXP Kinetis and Nordic nRF52 devices).
- `show graph` print the object model graph.
- Added `reset.hold_time` and `reset.post_delay` user options to fine tune hardware reset timings.

Boards and targets

- Fixed NXP i.MX RT1052 HyperFlash and QuadSPI flash programming. (Thanks jhqian!)
- Fixed reset vector catch clearing on LPC1768. (Thanks rafl!)

Changes

- Support for accessing banked DP registers.
- Improved DP power up and power down sequences to match the recommendations and add timeouts.
- The associated core number is printed for gdb and semihost servers when the port number is logged.
- An empty `logging.loggers` yaml key in the config file is ignored instead of reporting an error while attempting to configure logging.
- Commander changes:
- `status` only reports the core status now.
- `reg` only shows peripheral register fields if the `-f` option is passed.
- `wreg -r` option to perform a post-write read-back and print of the peripheral register value. The read-back is no longer performed automatically.

Fixes

- Fixed several cases where exceptions were incorrectly created.
- Fixed a missing import of `six` in `coresight_target.py`.
- Fixed `FileProgrammer` import issue for user scripts that appeared in certain cases.
- Corrected a "null internal" error when using certain ELF files.
- Solved a name error in `CortexM._map_from_vector_catch_mask()`.
- Fixed name error regression in `Breakpoint` repr() implementation.
- Commander always flushes after `wdp`, `wap`, and `wreg` commands.
- The gdb server ensures the target is halted when gdb first connects, to prevent gdb from failing to read the target state (i.e., core registers that cannot be read by the core is running).
- Fixed incorrect exception handlers in `DebugPort` that caused certain faults and timeouts to not be cleared in the DP.
- Corrected a number of naming and typing issues identified by pytype.
- Resolved a `KeyError` exception that would be raised by the RTX5 RTOS support when generating the thread description if a thread has an invalid state.

Internals

- `DebugPort` init uses a call sequence.
- Refactored DP connection into a `DPConnector` class.
- Refactored SWJ sequences into an `SWJSequenceSender` class
- Refactored CoreSight discovery to use a new `CoreSightDiscovery` class hierarchy. This allows the init sequence to be modified by an ADI version-specific subclass. These changes are preparatory work for ADIv6 support.
- Added a `CoreSightTarget.post_connect_hook()` method that can be overridden by builtin targets without having to modify the init sequence.
- `CortexM` and `CortexM_v8M` classes gained an `architecture` property that is a `CoreArchitecture.ARMv6M` enum of the Arm Cortex-M architecture: `ARMv6M`, `ARMv7M`, `ARMv8M_BASE`, `ARMv8M_MAIN`. Correspondingly, the `arch` attribute was removed from the classes.
- PMU halt reason support was moved to `CortexM_v8M`.

Testing

- New ROM table parser unit test.
- Basic user script functional test.

Documentation

- Fixed `user_script.md` reference to old `MemoryMap.get_region_by_name()` method that was replaced with `get_first_matching_region()`.

0.25.0

New features

- User scripts are run earlier, from the `Session` constructor. This allows user scripts to add new target classes.
- pyocd commander: Added `compare` command for comparing memory with a binary file.
- JSON features and options list, accessible via `pyocd json --features`. This is intended to allow IDEs to query for supported features and the set of available user options without having to make decisions based solely on the pyOCD version.

Boards and targets

- Added NXP FRDM-K32LB2 board and `k32l2b3` target. (Thanks jhqian.)
- Added NXP MIMXRT1010-EVK and MIMXRT1015-EVK boards and `mimxrt1010` and `mimxrt1015` targets.
(Thanks jhqian.)
- Added NuMaker-IoT-M263A board and `m263kiaae` target. (Thanks OpenNuvoton.)
- Added numerous HDSC MCU targets: `hc32l110`, `hc32f003`, `hc32f005`, `hc32l136`, `hc32l130`, `hc32f030`, `hc32l196`, `hc32l190`, `hc32f196`, `hc32f190`, `hc32l072`, `hc32l073`, `hc32f072`. (Thanks hdscmcu.)
- Improved support for Cypress PSoC64 device family. (Thanks Cypress-OpenOCD.)
- Corrected the UICR region size for Nordic nRF52x devices. (Thanks Dirbaio.)

Changes

- pyocd commander: `erase` command will perform a mass erase if no arguments are passed.
- pyocd erase: A much more helpful error is shown in no arguments are passed.
- Arguments for subcommands are grouped in the usage text.
- Adjusted pyOCD's CoreSight discovery process to only stop scanning for APs after two invalid APSEL addresses in sequence have been encountered (instead of 1).
- Relaxed the CMSIS-DAPv1 detection code for the pyusb backend to only require "CMSIS-DAP" in the HID interface name if there is more than one HID interface.

Fixes

- Much more robust detection of FreeRTOS. (Thanks haneefdm.)
- Fixed exception raised by the Zephyr RTOS support in cases where a thread's state was garbage for one reason or another. (Thanks FrameworkComputer.)
- Fixed bits versus bytes confusion in SWV processor. (Thanks Dirbaio.)
- CMSIS-DAP v2: fix support for USB full speed devices with a `DAP_PACKET_SIZE` larger than the bulk packet size. (Thanks vllogic.)
- Corrected some debug log messages in the `BreakpointManager`.
- pyocd commander: Fixed several issues when connecting to a device where no cores were discovered, when allowed by setting the `allow_no_cores` option.
- Fixed issues with passing the path to an FLM flash algo to a `FlashRegion` via the `flm` parameter.

Testing

- Added CMSIS-Pack parsing unit test.
- The `FileProgrammer` functional test now tests ELF files.

Installation

- Individual SVD files are now stored in the repo, and the `svd_data.zip` is built by `setup.py`.
- `setup.py` can be run from directories other than the repo root. (Thanks jsiverskog.)

Page 5 of 11

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.