nfc_reader¶
Probes internal USB NFC reader devices.
Function Arguments¶
Name |
Type |
Description |
---|---|---|
dir_path |
str, None |
(optional; default: |
Description¶
This function goes through /sys/bus/usb/devices/
to read attributes of
each usb device and find out all NFC readers there. Each result must contain
these fields:
device_path
: Pathname of the sysfs directory.idVendor
idProduct
The result might also contain these optional fields if they are exported in the sysfs entry:
manufacturer
product
bcdDevice
Because we cannot differentiate between keyboards and nfc readers, we make an explicit list of allowed (vid, pid).