Important
This library is in active development and has no stable release yet. Please, expect significant changes in the future as we work on the first major version release.
Easy to install and use, this library provides an essential API for any SX1280 LoRa module connected to your Raspberry Pi via the SPI interface.
In order to use this library install it first:
pip install rpi-sx1280
Now you can use it within your code.
import RPi.GPIO as GPIO
from rpi_sx1280.sx1280 import SX1280
GPIO.setmode(GPIO.BCM)
spi_idx = 0
spi_cs = 1
busy_gpio_idx = 22
reset_gpio_idx = 17
lora = SX1280(spi_idx, spi_cs, busy_gpio_idx, reset_gpio_idx)
If you'd like to work on the library itself here are a few things you should know.
This library by default uses the following tools, frameworks, etc.:
Python 3
- main supported languagehatch
- used as project management tool for PythonGitHub
- used as version control, issue tracking, docs
- Install python locally with pip. On Linux you can do this via:
sudo apt install python3-dev python3-pip
. - Now install
pipx
as it is usually better to installhatch
in this way to use it globally.sudo apt install pipx && pipx ensurepath
and re-init the shell session. - Ready to start, setup local environment with
hatch env create
.
This library follows the semver principles. You can use hatch
to update the version with necessary information.
To bump the version use hatch version <segment>
.
Here you can find the supported segments docs: hatch.io > supported segments
In order to publish the current state of the library you need to create a new tag and push it to the repository.
git tag -a 0.1.0 -m "Initial release"
git push origin 0.1.0
And the GitHub Actions will take care of the rest.