EBRPIH1118
EBRPIH1118 is a Python package designed to facilitate the control of hardware resources such as relays, digital inputs (DI), digital outputs (DO), analog inputs (AI), and temperature sensors on a Raspberry Pi. This package provides a convenient API to interact with GPIO pins and SPI devices, making it easy to develop automation applications on the Raspberry Pi.
Features
- Relay Control: Easily manage relays connected to the Raspberry Pi GPIO pins.
- Digital Input/Output: Read from and write to digital input/output pins.
- Analog Input: Read analog sensor data using SPI interface.
- Temperature Sensor Integration: Read data from 1-wire temperature sensors.
- Flexible Hardware Management: Abstract hardware interaction with a clean, easy-to-use API.
Installation
You can install EBRPIH1118 using pip. Ensure you have the necessary Python libraries for GPIO and SPI communication.
Prerequisites
Before installing EBRPIH1118, ensure that your Raspberry Pi is set up with the following libraries:
sudo apt-get update
sudo apt-get install python3-pip python3-rpi.gpio python3-spidev
Installing the Package
pip install EBRPIH1118
Usage
Importing the Package
from EBRPIH1118_intf import ebrpih1118
Example usage
from EBRPIH1118_intf import ebrpih1118
# Initialize GPIO and SPI
hardware_manager = ebrpih1118.EBRPIH1118()
# Example: Turn on relay #1
hardware_manager.energize_relay(relay_number=1)
# Example: Read an analog input from channel 1 to 4 (SPI)
analog_value = hardware_manager.read_ai_channels(channels="1,2,3,4")
print(f"Analog Input Values: {analog_value}")
# Cleanup after operations
hardware_manager.cleanup()
Steps to Contribute
Fork the repository. Create a new branch for your feature or bug fix. Make your changes. Submit a pull request to the main repository.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Acknowledgments
- This package uses the RPi.GPIO library for GPIO control.
- It also uses the spidev library for SPI communication.
More Information
For more details, visit our website: www.electronbits.com
Metadata
Release files for EBRPIH1118 0.1.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| EBRPIH1118-0.1.4.tar.gz | 6.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| EBRPIH1118-0.1.4-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 12.9 kB
Release files / EBRPIH1118-0.1.4.tar.gz
| Download URL | EBRPIH1118-0.1.4.tar.gz |
|---|---|
| Size | 6.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
bdebd9c4d6603e3966e9ace0e85937e620830f24f11168f9ab524df0824c9741
|
|
BLAKE2b-256 checksum How to use checksums |
f249d4f704dad6d56d57a0c6936ceb931176911410d3d21127288d4a7d9e74c8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.11.2
|
Release files / EBRPIH1118-0.1.4-py3-none-any.whl
| Download URL | EBRPIH1118-0.1.4-py3-none-any.whl |
|---|---|
| Size | 6.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b3545a7254eea02cbb1c5244846550471d82a3abeb3ea85df3ad0db7e36d2b25
|
|
BLAKE2b-256 checksum How to use checksums |
991e4a3dbfdbee1ce10bd50095fa71c4be19fdd7578acd3f931d252ba4fe532f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.11.2
|