API Reference¶
qwiic_rfid¶
Python module for the Qwiic RFID Reader.
This python package is a port of the existing [SparkFun Qwiic RFID Arduino Library](https://github.com/sparkfun/SparkFun_Qwiic_RFID_Arduino_Library)
This package can be used in conjunction with the overall [SparkFun qwiic Python Package](https://github.com/sparkfun/Qwiic_Py)
New to qwiic? Take a look at the entire [SparkFun qwiic ecosystem](https://www.sparkfun.com/qwiic).
-
class
qwiic_rfid.
QwiicRFID
(address=None, i2c_driver=None)[source]¶ - Parameters
address – The I2C address to use for the device. If not provied, the default address is used.
i2c_driver – An existing i2c driver object. If not provided a driver object is created.
- Returns
The RFID device object.
- Return type
Object
-
begin
()[source]¶ Initialize the operation of the Qwiic GPIO
- Returns
Returns true if the initialization was successful, otherwise False.
- Return type
void
-
change_address
(new_address)[source]¶ Changes the I2C address of the Qwiic RFID reader
- Parameters
new_address – the new address to set the RFID reader to
- Return type
bool
Reads and clears the tags from the buffer
- Return type
void - does not return anything
-
get_all_prec_times
(time_array)[source]¶ Gets all times in the buffer
- Parameters
time_array – list of upto 20 times the RFID tag was read from the I2C bus
- Return type
void - does not return anything
Gets all the tags in the buffer
- Parameters
tag_array – list of upto 20 RFID tag numbers
- Return type
void - does not return anything
-
get_prec_req_time
()[source]¶ Gets the time when the RFID tag was last scanned
- Returns
Returns time in seconds
- Return type
int
-
class
qwiic_rfid.
QwiicRFID
(address=None, i2c_driver=None)[source]¶ - Parameters
address – The I2C address to use for the device. If not provied, the default address is used.
i2c_driver – An existing i2c driver object. If not provided a driver object is created.
- Returns
The RFID device object.
- Return type
Object
-
begin
()[source]¶ Initialize the operation of the Qwiic GPIO
- Returns
Returns true if the initialization was successful, otherwise False.
- Return type
void
-
change_address
(new_address)[source]¶ Changes the I2C address of the Qwiic RFID reader
- Parameters
new_address – the new address to set the RFID reader to
- Return type
bool
-
clear_tags
()[source]¶ Reads and clears the tags from the buffer
- Return type
void - does not return anything
-
get_all_prec_times
(time_array)[source]¶ Gets all times in the buffer
- Parameters
time_array – list of upto 20 times the RFID tag was read from the I2C bus
- Return type
void - does not return anything
-
get_all_tags
(tag_array)[source]¶ Gets all the tags in the buffer
- Parameters
tag_array – list of upto 20 RFID tag numbers
- Return type
void - does not return anything
-
get_prec_req_time
()[source]¶ Gets the time when the RFID tag was last scanned
- Returns
Returns time in seconds
- Return type
int