Skip to main content

Chriesibaum's BSDL File Parser

pypi python PyPI - Downloads GitHub stars
Tests Status Coverage Status

When I was tinkering around with JTAG and BSDL files, I realized that there was no truly functional BSDL file parser for Python. Perhaps I simply didn't search hard enough. In any case, many packages are no longer up to date or have broken dependencies. Let's get our hands dirty - a few moments later and here is what I needed. If you can use it too, I'm happy to receive any inputs.

Basic usage:

Download and install the package from pypi.org. It's recommended to install the package into a virtual Python environment.

pip install cb_bsdl_parser

There are two tools available to examine BSDL files:

  • cb_bsdl_check: To check a BSDL file
  • cb_bsdl_info: To get basic data and info from a BSDL file
cb_bsdl_check <bsdl_file> [options]
cb_bsdl_info <bsdl_file> [--cell CELL] [--print-bsr-table]

To use it in your Python project, create a BSDL object and extract the needed data:

bsdl = CBBsdl('bsdl_file.bsdl')

bsdl.get_entity_name()

# get the pin mapping as a dict:
pin_map = bsdl.get_pin_map()

# or just print the boundary scan table:
bsdl.print_bsr_table()

There is a handful of more methods available to extract other data from the BSDL file.

Development

Dev tool installation

The development is mainly being done on an Ubuntu 24.04 box. To set up a dev environment, use Python 3 and install the following packages:

pip install -r requirements.txt
pip install -r requirements_dev.txt

To use antlr4, install it from the deb package sources/store:

sudo apt install antlr4

Note: If a Python virtual environment installs antlr4-tools, its antlr4 wrapper may fail offline with a .m2/repository/org/antlr/antlr4 error.

Current parser generation setup (no VSCode ANTLR required):

  • Preferred: venv-local jar at /tmp/venv_cb_bsdl_parser/tools/antlr4-4.13.2-complete.jar
  • Fallback: /usr/bin/antlr4
  • Last fallback: antlr4 from PATH

If needed, place a local ANTLR jar into the active venv:

source envsetup.sh
mkdir -p "$VIRTUAL_ENV/tools"
curl -fL -o "$VIRTUAL_ENV/tools/antlr4-4.13.2-complete.jar" \
	https://repo1.maven.org/maven2/org/antlr/antlr4/4.13.2/antlr4-4.13.2-complete.jar

About Café - The Heart of Coding! ;-)

Do you like this project and want to support it? I appreciate every single Café – it keeps me going! You can also sponsor the project on github sponsors? Thanks for your support!

Metadata

Release files for cb-bsdl-parser 0.12.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for cb-bsdl-parser 0.12.0
File Size Uploaded Provenance Actions
cb_bsdl_parser-0.12.0.tar.gz 169.2 kB With provenance Details for cb_bsdl_parser-0.12.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for cb-bsdl-parser 0.12.0
File Interpreter ABI Platform Actions
cb_bsdl_parser-0.12.0-py3-none-any.whl Python 3 none any Details for cb_bsdl_parser-0.12.0-py3-none-any.whl

Total release size: 243.1 kB

Release files / cb_bsdl_parser-0.12.0.tar.gz

Download URL cb_bsdl_parser-0.12.0.tar.gz
Size 169.2 kB
Tags Source
SHA-256 checksum
How to use checksums
18c167c0b0050fe6bd3308ba1cc0ba174c2dc2ffb8723de709b2782a09f26179
BLAKE2b-256 checksum
How to use checksums
cdc8d0bc8cde41cacd73a849ce23853323675f1cfa34f85b0900bcf42f8c63d2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jun 4, 2026.

Transparency log

Release files / cb_bsdl_parser-0.12.0-py3-none-any.whl

Download URL cb_bsdl_parser-0.12.0-py3-none-any.whl
Size 73.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c50f5efd0e2f628fecab999be596cbfddad0805761160f564a887391adf110bf
BLAKE2b-256 checksum
How to use checksums
70dd9118f5f7874752d87044436a1bd7bc0d7f903f6d2b4b4dfe2061789ae28c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jun 4, 2026.

Transparency log

Security for cb-bsdl-parser 0.12.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for cb_bsdl_parser-0.12.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jun 4, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page