* Wired like: https://circuitdigest.com/microcontroller-projects/wireless-rf-communication-between-arduino-and-raspberry-pi-using-nrf24l01 * I used script: https://github.com/BLavery/lib_nrf24/blob/master/example-nrf24-recv-rpi.py ... thank you Brian Lavery 👍 * radio2.begin(0, 25) csn=0 means pin nrf24-csn to rpi-gpio8 (CE0_N) and pin nrf24-ce to rpi-gpio25 * while True: .... akpl_buf = [(c& 255), ... (like in another example) * I change library https://github.com/BLavery/lib_nrf24/blob/master/lib_nrf24.py : * after lines self.spidev.open(0, csn_pin) self.ce_pin = ce_pin i add line: * self.spidev.max_speed_hz=(4000000); because: https://github.com/nRF24/RF24/issues/205#issuecomment-180104230 * and to line 226 i use line "if isinstance(value, (int, long)):" (not: "if isinstance(value, int)") * -------------------------------------------------- Commands on raspberry pi zero (virgin sd card with Raspberry Pi OS Lite): * sudo raspi-config ... to config. wifi (ssid and password) * sudo apt update * sudo apt full-upgrade * sudo apt install git * sudo git clone https://github.com/BLavery/lib_nrf24 * cd lib_nrf24 * sudo nano example-nrf24-recv-rpi.py ....... see modification * sudo nano lib_nrf24.py ...... see modification * sudo apt-get install python-pip * sudo pip install spidev * sudo python example-nrf24-recv-rpi.py * -------------------------------------------------- * Sorry for my bad english * Other links: * https://raspberrypi.stackexchange.com/questions/12966/what-is-the-difference-between-board-and-bcm-for-gpio-pin-numbering * https://www.raspberrypi.org/forums/viewtopic.php?t=111353 * https://www.rhydolabz.com/wiki/?p=15956 * https://www.raspberrypi.org/documentation/hardware/raspberrypi/spi/README.md * https://github.com/lthiery/SPI-Py * https://forum.mysensors.org/topic/1887/what-s-the-difference-between-nrf24l01-and-nrf24l01
Wired like: https://circuitdigest.com/microcontroller-projects/wireless-rf-communication-between-arduino-and-raspberry-pi-using-nrf24l01
I used script: https://github.com/BLavery/lib_nrf24/blob/master/example-nrf24-recv-rpi.py ... thank you Brian Lavery 👍
radio2.begin(0, 25) csn=0 means pin nrf24-csn to rpi-gpio8 (CE0_N) and pin nrf24-ce to rpi-gpio25
while True: .... akpl_buf = [(c& 255), ... (like in another example)
I change library https://github.com/BLavery/lib_nrf24/blob/master/lib_nrf24.py :
after lines self.spidev.open(0, csn_pin) self.ce_pin = ce_pin i add line:
self.spidev.max_speed_hz=(4000000); because: RasPI: HARDWARE FAIL: Radio not responding, verify pin connections, wiring, etc. nRF24/RF24#205 (comment)
and to line 226 i use line "if isinstance(value, (int, long)):" (not: "if isinstance(value, int)")
Commands on raspberry pi zero (virgin sd card with Raspberry Pi OS Lite):
sudo raspi-config ... to config. wifi (ssid and password)
sudo apt update
sudo apt full-upgrade
sudo apt install git
sudo git clone https://github.com/BLavery/lib_nrf24
cd lib_nrf24
sudo nano example-nrf24-recv-rpi.py ....... see modification
sudo nano lib_nrf24.py ...... see modification
sudo apt-get install python-pip
sudo pip install spidev
sudo python example-nrf24-recv-rpi.py
Sorry for my bad english
Other links:
https://raspberrypi.stackexchange.com/questions/12966/what-is-the-difference-between-board-and-bcm-for-gpio-pin-numbering
https://www.raspberrypi.org/forums/viewtopic.php?t=111353
https://www.rhydolabz.com/wiki/?p=15956
https://www.raspberrypi.org/documentation/hardware/raspberrypi/spi/README.md
https://github.com/lthiery/SPI-Py
https://forum.mysensors.org/topic/1887/what-s-the-difference-between-nrf24l01-and-nrf24l01