python-inklevel
Python wrapper for libinklevel.
Prerequisites
Install libinklevel, e.g. on Debian:
apt-get install libinklevel
Installation
pip install inklevel
Usage
import inklevel
# libinklevel version
print(inklevel.get_version_string())
# Get data from /dev/usb/lp0:
data = inklevel.get_usb_ink_level(0)
for cartridge, value in data.levels:
print('{}: {}'.format(cartridge.description, value))
# Get data from /dev/parport2
data = inklevel.get_parport_ink_level(2)
The functions get_usb_ink_level and get_parport_ink_level are convenience functions using the original libinklevel interface. You can also use that:
data = inklevel.get_ink_level(inklevel.Port.USB, None, 0) data = inklevel.get_ink_level(inklevel.Port.CUSTOM_USB, '/dev/usb/lp0', None)
See libinklevel and ink for details.
License
This software is licensed under GPLv2.
Metadata
Release files for inklevel 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| inklevel-0.1.2-py2.py3-none-any.whl | Python 3, Python 2 | none | any | Details for inklevel-0.1.2-py2.py3-none-any.whl |
Release files / inklevel-0.1.2-py2.py3-none-any.whl
| Download URL | inklevel-0.1.2-py2.py3-none-any.whl |
|---|---|
| Size | 5.9 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
6e270b78eb2b6484054f437f5c22e483b2050e7dcdb6a72a0edb4b11af4193c5
|
|
BLAKE2b-256 checksum How to use checksums |
d6c412cc2e3740de7fd2faeaf67f66c686e45a143bdbca0aa632f496b182f45a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for inklevel 0.1.2
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.
No provenance found
None of the files in this release were uploaded with provenance metadata.
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.