Skip to main content

HX711

PyPi

Travis

Description

This library allows to drive a HX711 load cess amplifier with a Raspberry Pi. It just provides the capabilities:

  • to set channel an gain and
  • to read raw values

This package requires RPi.GPIO to be installed in Python 3.

Getting started

Just install by pip3 install HX711. A basic usage example is given below:

    #!/usr/bin/python3
    from hx711 import HX711

    try:
        hx711 = HX711(
            dout_pin=5,
            pd_sck_pin=6,
            channel='A',
            gain=64
        )

        hx711.reset()   # Before we start, reset the HX711 (not obligate)
        measures = hx711.get_raw_data(num_measures=3)
    finally:
        GPIO.cleanup()  # always do a GPIO cleanup in your scripts!

    print("\n".join(measures))

License

  • Free software: MIT license

Credits

I used https://github.com/gandalf15/HX711/ as base.

This package was created with Cookiecutter_ and the audreyr/cookiecutter-pypackage_ project template.

Download files

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

Source Distribution

hx711-1.1.2.2.tar.gz (16.5 kB view details)

Uploaded Source

Built Distribution

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

hx711-1.1.2.2-py3-none-any.whl (5.2 kB view details)

Uploaded Python 3

File details

Details for the file hx711-1.1.2.2.tar.gz.

File metadata

  • Download URL: hx711-1.1.2.2.tar.gz
  • Upload date:
  • Size: 16.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for hx711-1.1.2.2.tar.gz
Algorithm Hash digest
SHA256 a04d86f887a7a290d1dff4580767bab893c7186654bbe7a8cd7d95e5c42c8417
MD5 664b3d0bd2b83ab471e36d9f7359202a
BLAKE2b-256 e044535330e11cd65064ad20294be4911f681e8013b223999de8105f25c7b0ea

See more details on using hashes here.

File details

Details for the file hx711-1.1.2.2-py3-none-any.whl.

File metadata

File hashes

Hashes for hx711-1.1.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 5d6d7df7df2a8b17b6cde98dabc4e602c70a2c2313e3c7196a96b85e5c9fd69a
MD5 07842ad84ea1813072b5b092c3446e43
BLAKE2b-256 5327eed11328a9d8f99d4c7602522837a0f6e64ad3d32fa379469c89bbd6fdde

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