Skip to main content

python-inklevel

Build Status

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.

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)

Table of built distributions (wheels) for inklevel 0.1.2
File Interpreter ABI Platform
inklevel-0.1.2-py2.py3-none-any.whl Python 3, Python 2 none any Details

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

Release history Release notifications | RSS feed

This release

0.1.2 This release

1 release file

0.1.1

1 release file

0.1

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