Skip to main content

pypci, a pciutils-like library for fetching system PCI/PCI-E information but written mostly in python.

Project description

pypci-ng

Downloads PyPI - Version

Static Badge Static Badge Static Badge

pypci-ng, a pciutils-like library for fetching system PCI/PCI-E devices but written mostly in python. Currently, this package ONLY implements the same functionality as lspci, i.e. scanning and listing all PCI/PCI-E devices. More functionalities are under development.

demo0

demo1

Install

Just install it directly by pip.

pip install pypci-ng

To upgrade pypci:

pip install pypci-ng --upgrade

Usage

Use as a command line tool

You can use this tool directly from the command line with the following command, just like lspci.

pypci

Or use -d flag to print driver information.

pypci -d

For more command line flags, see:

pypci -h

Please note that the command line entry for pypci is created by pip, and depending on the user, this entry may not in the system PATH. If you encounter this problem, pip will give you a prompt, follow the prompts to add entry to the system PATH.

Use as a Python Package

You can also use this package in Python, here is the demo:

import pypci
pci = pypci.PCI()
vga_devices = pci.FindAllVGA()
nic_devices = pci.FindAllNIC()

More functionalities are under development.

Supported (Tested) OS

  • Linux
  • Windows 10 and above

Build from source

Build tools

Make sure the following Python build tools are already installed.

  • setuptools
  • build
  • twine

Build package

clone the project, and run:

python -m build

After the build process, the source package and the binary whl package can be found in the dist folder.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pypci_ng-0.3.2.tar.gz (1.0 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pypci_ng-0.3.2-py3-none-any.whl (1.1 MB view details)

Uploaded Python 3

File details

Details for the file pypci_ng-0.3.2.tar.gz.

File metadata

  • Download URL: pypci_ng-0.3.2.tar.gz
  • Upload date:
  • Size: 1.0 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.20

File hashes

Hashes for pypci_ng-0.3.2.tar.gz
Algorithm Hash digest
SHA256 08506b7f2c127d73ca0926c550a35f287c74d2b6e4f5712c049bc4dc17a620fe
MD5 5f0a7dc0a95c71d37d52ce3738f30cdb
BLAKE2b-256 4536b47125d4d73535b5ef0721ee806a49ee3f86492c8a2ba80204a9b2a02dae

See more details on using hashes here.

File details

Details for the file pypci_ng-0.3.2-py3-none-any.whl.

File metadata

  • Download URL: pypci_ng-0.3.2-py3-none-any.whl
  • Upload date:
  • Size: 1.1 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.20

File hashes

Hashes for pypci_ng-0.3.2-py3-none-any.whl
Algorithm Hash digest
SHA256 d65d0b4ea8cec5c8aa2dea5dc246d1569554b2e7a9d4f734f4a774c60d32031f
MD5 282dba7006b0e0a570b7ae8a75689961
BLAKE2b-256 fe7f59ab9914251f685fc33c485c293b9cf30c7d3f3c0ffae3725b831388fba3

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page