nRF24 / pyRF24

A python package that wraps the RF24, RF24Network, and RF24Mesh C++ libraries.
http://pyrf24.rtfd.io
GNU General Public License v2.0
24 stars 3 forks source link

Expose RF24_DRIVER and fix linking to shared utility driver libs #46

Closed 2bndy5 closed 8 months ago

2bndy5 commented 8 months ago

This leverages CMake's target_compile_definitions() to expose the selected RF24_DRIVER as a module attribute. I wanted this to programmatically declare the right pin numbers in the examples.

https://github.com/nRF24/pyRF24/blob/79e9808b95782189a4757b0afd2f91b6a199ac20/examples/getting_started.py#L9-L26

[!IMPORTANT] In testing this, I found and fixed a problem when building this package with utility drivers pigpio, MRAA, and wiringPi. All of which were not properly found and linked to during the build... This constitutes a minor version bump.

Also replaced usage of pylint and black with ruff for linting and formatting python code.