Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create PN532 UART sample config for Raspberry Pi 5, fix older Raspberry Pi configuration #731

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions contrib/libnfc/pn532_uart_on_rpi.conf.sample
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
## Typical configuration file for PN532 device on R-Pi connected using UART
## Note: to use UART port on R-Pi, you have to disable linux serial console:
## http://learn.adafruit.com/adafruit-nfc-rfid-on-raspberry-pi/freeing-uart-on-the-pi
##
## For more information about UART differences between R-Pi models, visit:
## https://www.raspberrypi.com/documentation/computers/configuration.html#configure-uarts
##
name = "PN532 board via UART"
connstring = pn532_uart:/dev/ttyAMA0
14 changes: 11 additions & 3 deletions contrib/libnfc/pn532_uart_on_rpi_3.conf.sample
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,27 @@
## use the PN532 device with the "mini UART", which is still hijacked by the linux kernel
## as a serial console
##
## For more information about UART differences between R-Pi models, visit:
## https://www.raspberrypi.com/documentation/computers/configuration.html#configure-uarts
##
## Tested recipe with PN532 breakout from Adafruit
##
## To enable uart on GPIO, add this line to bottom of /boot/config.txt
## To enable uart on GPIO, add this line to bottom of /boot/firmware/config.txt
## enable_uart=1
##
## If you are using an earlier version of Raspberry Pi OS (prior to Bookworm),
## the config file is available instead on /boot/config.txt.
##
## Stop and disable serial console:
## $ sudo systemctl stop [email protected]
## $ sudo systemctl disable [email protected]
##
## Remove console from /boot/cmdline.txt by removing:
## Remove console from /boot/firmware/cmdline.txt by removing:
## console=serial0,115200 Save and reboot for changes to take effect.
##
## If you are using an earlier version of Raspberry Pi OS (prior to Bookworm),
## the config file is available instead on /boot/cmdline.txt.
##
name = "PN532 board via UART"
connstring = pn532_uart:/dev/ttyS0
allow_intrusive_scan = true

22 changes: 22 additions & 0 deletions contrib/libnfc/pn532_uart_on_rpi_5.conf.sample
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
## Typical configuration file for PN532 device on R-Pi 5
## Note: Changes have been made to R-Pi 5 with the removal of the mini UART
## (/dev/ttyS0), hence the module can be accessed through the original R-Pi
## UART address (/dev/ttyAMA0).
##
## For more information about UART differences between R-Pi models, visit:
## https://www.raspberrypi.com/documentation/computers/configuration.html#configure-uarts
##
## This configuration is almost identical to pn532_uart_on_rpi.conf.sample
## except the allow_intrusive_scan option from the R-Pi 3 sample.
##
## Tested recipe with generic PN532 module (common Elechouse module clones)
##
## To enable uart on GPIO, add this line to bottom of /boot/firmware/config.txt
## enable_uart=1
##
## If you are using an earlier version of Raspberry Pi OS (prior to Bookworm),
## the config file is available instead on /boot/config.txt.
##
name = "PN532 board via UART"
connstring = pn532_uart:/dev/ttyAMA0
allow_intrusive_scan = true