Skip to main content

cjn's library of Raspberry Pi functions, drivers, tools, ...

Project description

cjn_PiTools - A collection of modules for Raspberry Pi projects

cjn_PiTools is comprised of several modules (follow links to respective documentation)

NOTE: These links point to the github repo since relative links to other .md files do not work on PyPI.

Module Description/Purpose
PiBlinky A multiple threaded LED driver for Raspberry Pi
PiOLED Display multi-line messages on a shared Raspberry Pi connected OLED display
DS18B20 A high-featured library/driver using the w1_therm kernel driver
initW1buses Initialize the W1 buses and set write permission on found therm_bulk_read file(s)

More to come!

  • Drivers for SHT3x and HTU21D temp/RH sensors
  • Driver for ADC121C027 ADC
  • Driver for MCP23008 IO expander
  • Driver for PCA9548s I2C expander

In most cases, these drivers will work with both RPi.GPIO (for local control) and pigpio for (local and remote control).

Developed and tested on Raspbian GNU/Linux 11 (bullseye) and Python 3.9.2, and supported on all higher versions.

In this documentation, "tool script" refers to a Python project that imports and uses cjn_PiTools. Some may be simple scripts, and others may themselves be installed packages.


Installation and usage

If using the RPi.GPIO driver:

pip install cjn_PiTools

If using the pigpio driver:

pip install cjn_PiTools[pigpio]
  • And you will also need to install the pigpiod daemon (sudo apt install pigpiod) and start it manually or at boot. Here's a systemd service file for starting pigpiod at boot:

      [Unit]
      Description=Daemon required to control GPIO pins via pigpio
    
      [Service]
      ExecStart=/usr/local/bin/pigpiod -l
      Type=forking
      TimeoutStopSec=20
    
      [Install]
      WantedBy=multi-user.target
    

Key changes since the prior major public release (this is the first release)

  • New. Bundled PiBlinky, PiOLED, initW1buses, and DS18B20 modules

Revision history

  • 1.0 260207 - New. Bundled PiBlinky, PiOLED, initW1buses, and DS18B20 modules

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

cjn_pitools-1.0.1.tar.gz (4.1 MB view details)

Uploaded Source

Built Distribution

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

cjn_pitools-1.0.1-py3-none-any.whl (4.1 MB view details)

Uploaded Python 3

File details

Details for the file cjn_pitools-1.0.1.tar.gz.

File metadata

  • Download URL: cjn_pitools-1.0.1.tar.gz
  • Upload date:
  • Size: 4.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.9

File hashes

Hashes for cjn_pitools-1.0.1.tar.gz
Algorithm Hash digest
SHA256 eec8069e4f77a4d815078817895270185b9a21b19d3513c39df54921eb5db83f
MD5 d4ed39454b04245219328f538cc36614
BLAKE2b-256 4c4ac4cf8f0c51a2bb23e934696366f0aeb3be9bd2adb04a0c6a171b40f4fe8a

See more details on using hashes here.

File details

Details for the file cjn_pitools-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: cjn_pitools-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 4.1 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.9

File hashes

Hashes for cjn_pitools-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 dcdcda6ecdd08a3b40e91c11710f4251122503a87a200cbe228d7ef1a650a5eb
MD5 e955ac018cdaf38a5c5136e9130bc7e1
BLAKE2b-256 f82619ea81b857b4c2f7101e60f236c67e80ddc9f63f7a2ec0dbad6a60ffae3e

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