Zephyr API Documentation 4.3.99
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
Biometrics emulator test helpers

Biometrics emulator test control functions. More...

Functions

void biometrics_emul_set_match_score (const struct device *dev, int score)
 Set the match score for the biometrics emulator.
void biometrics_emul_set_match_id (const struct device *dev, int id)
 Set the template ID for identification matches.
void biometrics_emul_set_match_fail (const struct device *dev, bool fail)
 Set whether match operations should fail.
void biometrics_emul_set_capture_timeout (const struct device *dev, bool timeout)
 Set whether capture operations should timeout.
void biometrics_emul_set_image_quality (const struct device *dev, int quality)
 Set the image quality score.
enum biometric_led_state biometrics_emul_get_led_state (const struct device *dev)
 Get the current LED state.

Detailed Description

Biometrics emulator test control functions.

Function Documentation

◆ biometrics_emul_get_led_state()

enum biometric_led_state biometrics_emul_get_led_state ( const struct device * dev)

#include <zephyr/drivers/biometrics/emul.h>

Get the current LED state.

Retrieves the current LED state that was set via biometric_led_control(). Used for verifying LED control commands.

Parameters
devPointer to the biometrics device
Returns
Current LED state

◆ biometrics_emul_set_capture_timeout()

void biometrics_emul_set_capture_timeout ( const struct device * dev,
bool timeout )

#include <zephyr/drivers/biometrics/emul.h>

Set whether capture operations should timeout.

Configures the emulator to simulate capture timeouts. When enabled, enrollment capture operations will return -ETIMEDOUT.

Parameters
devPointer to the biometrics device
timeoutTrue to simulate timeout, false for normal operation

◆ biometrics_emul_set_image_quality()

void biometrics_emul_set_image_quality ( const struct device * dev,
int quality )

#include <zephyr/drivers/biometrics/emul.h>

Set the image quality score.

Configures the image quality score that will be returned by capture and match operations. Used for testing quality feedback.

Parameters
devPointer to the biometrics device
qualityQuality score (0-100)

◆ biometrics_emul_set_match_fail()

void biometrics_emul_set_match_fail ( const struct device * dev,
bool fail )

#include <zephyr/drivers/biometrics/emul.h>

Set whether match operations should fail.

Configures the emulator to fail match operations with -ENOENT. Used for testing match failure scenarios.

Parameters
devPointer to the biometrics device
failTrue to fail match operations, false for normal operation

◆ biometrics_emul_set_match_id()

void biometrics_emul_set_match_id ( const struct device * dev,
int id )

#include <zephyr/drivers/biometrics/emul.h>

Set the template ID for identification matches.

Configures which template ID will be returned when performing an IDENTIFY match operation. Used for testing identification scenarios.

Parameters
devPointer to the biometrics device
idTemplate ID to return on successful match

◆ biometrics_emul_set_match_score()

void biometrics_emul_set_match_score ( const struct device * dev,
int score )

#include <zephyr/drivers/biometrics/emul.h>

Set the match score for the biometrics emulator.

Configures the confidence/match score that will be returned by the next match operation. Used for testing match verification and identification.

Parameters
devPointer to the biometrics device
scoreMatch score to return (sensor-specific scale)