You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The [SparkFun Fingerprint Sensor - FPC2534 Pro]() is a small, highly capable and robust fingerprint sensor that can easily be integrated into virutally any application. Based off the AllKey Biometric System family from Fingerprints Cards (FPC), the FPC2534AP delivers incredible functionality in a small, compact formfactor.
15
+
The [SparkFun Fingerprint Sensor - FPC2534 Pro]() is a small, highly capable and robust fingerprint sensor that can easily be integrated into virtually any application. Based off the AllKey Biometric System family from Fingerprints Cards (FPC), the FPC2534AP delivers incredible functionality in a small, compact formfactor.
16
16
17
17
## Functionality
18
18
19
-
The SparkFun Fingerprint Sensor - FPC2534 Pro is accessable via a variety of interfaces, including I2C and UART, which are supported by this library.
19
+
The SparkFun Fingerprint Sensor - FPC2534 Pro is accessible via a variety of interfaces, including I2C and UART, which are supported by this library.
20
20
21
-
This library provides a message-based, easy to use interface that enables fingerprint biometric authentication and simple finger-based navigation. Specificatlly, the FPC2534AP provides:
21
+
This library provides a message-based, easy to use interface that enables fingerprint biometric authentication and simple finger-based navigation. Specifically, the FPC2534AP provides:
22
22
23
23
- Fingerprint enrollment - adding a fingerprint to the sensor
24
24
- Fingerprint template management - managing recorded fingerprints
25
-
- Fingerprint matching/indentification for biometric authentication
26
-
- Trackpad like functionalality for simple, finger-based navigation
25
+
- Fingerprint matching/identification for biometric authentication
26
+
- Trackpad like functionality for simple, finger-based navigation
27
27
- Application integration via a variety of communication methods
28
28
29
29
### Functionality not Supported by the Library
@@ -38,7 +38,7 @@ If any of these advanced features are desired for use, an implementation can be
38
38
39
39
## Communication
40
40
41
-
The operation of the FPC2534AP is performed by a messaging protocol implemented on the device. A client application sends message requests to the sensor and recieves responses to the request made.
41
+
The operation of the FPC2534AP is performed by a messaging protocol implemented on the device. A client application sends message requests to the sensor and receives responses to the request made.
42
42
43
43
To support integration and messaging, the FPC2534AP provides support for four (4) different communication implementations. These are:
44
44
@@ -47,10 +47,10 @@ To support integration and messaging, the FPC2534AP provides support for four (4
47
47
- SPI
48
48
- USB
49
49
50
-
The communication method used is selected via a pair of configuration jumpers on the SparkFun Fingerprint Sensor - FPC2534 Pro board. Further information on the use is oulined in the associated Hookup Guide for the SparkFun fingerprint breakout board.
50
+
The communication method used is selected via a pair of configuration jumpers on the SparkFun Fingerprint Sensor - FPC2534 Pro board. Further information on the use is outlined in the associated Hookup Guide for the SparkFun fingerprint breakout board.
51
51
52
52
> [!NOTE]
53
-
> The I2C (qwiic) interface for the SparkFun Fingerprint Sensor - FPC2534 Pro board is currently only supported on ESP32 and Raspberry RP2 (RP2040, RP2350) boards. The I2C Implemention of the FPC2534 device performs a dynamic payload transmission that is not supported by the Arduino Wire library. Because of this, a custom implementation is provided by this library for the ESP32 and RP2 platforms.
53
+
> The I2C (qwiic) interface for the SparkFun Fingerprint Sensor - FPC2534 Pro board is currently only supported on ESP32 and Raspberry RP2 (RP2040, RP2350) boards. The I2C implementation of the FPC2534 device performs a dynamic payload transmission that is not supported by the Arduino Wire library. Because of this, a custom implementation is provided by this library for the ESP32 and RP2 platforms.
54
54
55
55
### Additional Connections
56
56
@@ -59,26 +59,26 @@ In addition to the communication method selected, the FPC2534AP requires additio
59
59
| Pin | Use | Notes |
60
60
| -- | -- | -- |
61
61
|RST | Reset Device | Setting the pin low, then high will reset the FPC2534AP, placing it into a known state|
62
-
|IQ| IRQ/Interrupt Request|Used by the sensor to signal a new message/data availablity - note: this is not required when using the serial interface|
62
+
|IQ| IRQ/Interrupt Request|Used by the sensor to signal a new message/data availability - note: this is not required when using the serial interface|
63
63
64
64
## Library
65
65
66
-
Unlike a majority of sensors and their associated libraries which are synchronous function calls - a function/method call returns a requested value or performs a specific action - the FPC2534AP operates using a messaging methodlogy - sending messages to the client as actions occur on the device, or in reponse to earlier requests.
66
+
Unlike a majority of sensors and their associated libraries which are synchronous function calls - a function/method call returns a requested value or performs a specific action - the FPC2534AP operates using a messaging methodology - sending messages to the client as actions occur on the device, or in response to earlier requests.
67
67
68
-
Since messaging methodology is used by the FPC2534AP, this library makes makese use of the following implementation pattern:
68
+
Since messaging methodology is used by the FPC2534AP, this library makes use of the following implementation pattern:
69
69
70
-
- User provided callback functions that the library calls when a specific message is recieved from the library (like when a finger is pressed on the sensor).
70
+
- User provided callback functions that the library calls when a specific message is received from the library (like when a finger is pressed on the sensor).
71
71
- A process message method that is called to process the next available message from the sensor if one is available. This method is called within your applications main processing loop (for Arduino, this is the `loop()` function).
72
72
73
-
While this methodlogy is unique to the when compaired to other libraries, it fits well with the event driven nature of the FPC2534AP fingerprint sensor.
73
+
While this methodology is unique to the when compared to other libraries, it fits well with the event driven nature of the FPC2534AP fingerprint sensor.
74
74
75
75
### Using the Library
76
76
77
-
The first step to using the library is selected the method used to communicate with the device. The library supports I2C on select platforms, or UART (a Serial interface in Arduino). Once selected, and device connected as outlined in the hookup guide for theSparkFun Fingerprint Sensor - FPC2534 Pro. The type of connection depends on the method used to communicate with the device.
77
+
The first step to using the library is selected the method used to communicate with the device. The library supports I2C on select platforms, or UART (a Serial interface in Arduino). Once selected, and device connected as outlined in the hookup guide for the SparkFun Fingerprint Sensor - FPC2534 Pro. The type of connection depends on the method used to communicate with the device.
78
78
79
79
#### Getting Started
80
80
81
-
How the sensor is initialized is dependant on the communication method being utilized. The following sections outline how to use setup and initialize the I2C or UART interfaces to the device. Once setup, the operation of the device is communication method independant.
81
+
How the sensor is initialized is dependent on the communication method being utilized. The following sections outline how to use setup and initialize the I2C or UART interfaces to the device. Once setup, the operation of the device is communication method independent.
82
82
83
83
##### Using I2C (Qwiic)
84
84
@@ -106,7 +106,7 @@ At this point, the sensor is ready for normal operation.
106
106
107
107
###### A note on "pinging" the FPC2534 sensor
108
108
109
-
Often, to determine if a sensor is available on the I2C bus, the bus is queried at the address for the device (a simple "ping"). In arduino this often looks like:
109
+
Often, to determine if a sensor is available on the I2C bus, the bus is queried at the address for the device (a simple "ping"). In Arduino this often looks like:
110
110
111
111
```c++
112
112
// Is the sensor there - on the I2C bus?
@@ -118,7 +118,7 @@ Often, to determine if a sensor is available on the I2C bus, the bus is queried
118
118
Developing with the sensor has shown that once the sensor is "pinged", it enters an unknown state. To ensure proper device operation, a `reset()` of the device is needed after a `ping` operation is performed.
119
119
120
120
> [!NOTE]
121
-
> The I2C (qwiic) interface for the SparkFun Fingerprint Sensor - FPC2534 Pro board is currently only supported on ESP32 and Raspberry RP2 (RP2040, RP2350) boards. The I2C Implemention of the FPC2534 device performs a dynamic payload transmission that is not supported by the Arduino Wire library. Because of this, a custom implementation is provided by this library for the ESP32 and RP2 platforms.
121
+
> The I2C (qwiic) interface for the SparkFun Fingerprint Sensor - FPC2534 Pro board is currently only supported on ESP32 and Raspberry RP2 (RP2040, RP2350) boards. The I2C implementation of the FPC2534 device performs a dynamic payload transmission that is not supported by the Arduino Wire library. Because of this, a custom implementation is provided by this library for the ESP32 and RP2 platforms.
122
122
123
123
##### Using UART (Serial)
124
124
@@ -138,7 +138,7 @@ Configure the following settings on the UART/Serial connection being used:
138
138
| Read Buffer Size | 512|
139
139
140
140
> [!NOTE]
141
-
> Due to the amount of information sent by the fingerprint sensor, the default size of the internal buffer used by Arduino Serial objects is rapidly exceeded. To prevent this, the buffer size must be increased before initializing the FPC2534AP device.
141
+
> Due to the amount of information sent by the fingerprint sensor, the default size of the internal buffer used by Arduino Serial objects is rapidly exceeded. To prevent this, the buffer size must be increased before initializing the FPC2534AP device.
142
142
>
143
143
> To increase the buffer size when using a Raspberry pi RP2 Microcontroller:
144
144
>
@@ -182,9 +182,44 @@ The operational pattern for the SparkFun FPC2543 Fingerprint sensor library is o
182
182
183
183
The loop sequence of operation - make a request, check for messages and respond via callback functions continue during the operation of the sensor.
184
184
185
+
##### Callback Functions
186
+
187
+
The results from the FPC2543 sensor are reported through the use of callback functions, which are user provided. While more advanced that standard functional programming, this implementation pattern is recommended by the FPC2543 manufacturer and fits nicely with the operational use of the sensor.
188
+
189
+
Callback functions are assigned with a structure of type ```sfDevFPC2534Callbacks_t```, which is passed to the library during the setup sequence.
190
+
191
+
The following callbacks are available for use:
192
+
193
+
| Callback Name | Description|
194
+
| -- | -- |
195
+
|on_error| Called when the sensor send an error message. An error code is provided|
196
+
|on_status| Called with status update information from the sensor|
197
+
|on_version| Called as a result of a version request. The version string is passed to the callback|
198
+
|on_enroll| Called during a fingerprint enrollment process. The number of samples remaining and feedback are provided|
199
+
|on_list_templates | Called with the results of a ```requestListTemplates()``` call|
200
+
|on_navigation| Called when a navigation event is sent from the sensor|
201
+
|on_gpio_control| Called as the result of a GPIO get request call|
202
+
|on_system_config_get| Called when the system config is requested|
203
+
|on_bist_done| Called when the built-in testing routine is finished. The result of this test is provided|
204
+
|on_mode_change| Called when the mode of the sensor changes|
205
+
|on_finger_change | Called when the finger presence on the sensor changes|
206
+
|on_is_read_change| Called when the ready status of the sensor changes|
207
+
208
+
##### Startup Status Message
209
+
210
+
When the FPC2534 starts up, it posts a *is ready for use* status message, which can be detected within the ```on_status()``` callback function if provided to the library.
211
+
212
+
Another option is to register a ```on_is_ready_change()``` callback function, which is called when the ready state of the sensor changes. This simplifies the required implementation for using the sensor.
213
+
214
+
It the examples provided with this library, the ```on_is_ready_change()``` callback is used to determine when the sensor is ready for operation. When this callback is called with a "ready" value, the examples begin FPC2543 operations.
215
+
216
+
#### Error Conditions
217
+
218
+
If an error is reported by the sensor, the error value is pass to the registered ```on_error()``` callback function.
219
+
185
220
#### Navigation Mode
186
221
187
-
One of the operating modes of FPC2534 is *Navigation Mode*. Enabled by calling the ```startNavigationMode()``` on the library, the FPC2534 acts like a small touch pad/joystick when in Navigation Mode. It should be noted, the ```startNavigationMode()``` method also takes a parameter that sets the oriengation of the sensor. This is used when determining event type (up, down, left, right).
222
+
One of the operating modes of FPC2534 is *Navigation Mode*. Enabled by calling the ```startNavigationMode()``` on the library, the FPC2534 acts like a small touch pad/joystick when in Navigation Mode. It should be noted, the ```startNavigationMode()``` method also takes a parameter that sets the orientation of the sensor. This is used when determining event type (up, down, left, right).
188
223
189
224
Events from this mode are communicated to the callback function assigned in the ```on_navigation``` field of the callback function structure that is passed to the library. The following events are supported:
190
225
@@ -225,7 +260,7 @@ This process is outlined in the following diagram:
225
260
3) A standard *loop*()* application pattern/method is started.
226
261
4) The method ```processNextResponse()``` is called on the library to get updates from the sensor.
227
262
5) The library identifies and parse an enrollment status message from the sensor
228
-
6) The registered ```on_eroll()``` callback method is called, with the number of samples remaining.
263
+
6) The registered ```on_enroll()``` callback method is called, with the number of samples remaining.
229
264
- If the number is equal to zero, the process is complete and the fingerprint is enrolled/registered with the sensor.
0 commit comments