|
| enum | cs40l5x_attenuation {
CS40L5X_ATTENUATION_7DB = -7
, CS40L5X_ATTENUATION_6DB
, CS40L5X_ATTENUATION_5DB
, CS40L5X_ATTENUATION_4DB
,
CS40L5X_ATTENUATION_3DB
, CS40L5X_ATTENUATION_2DB
, CS40L5X_ATTENUATION_1DB
, CS40L5X_ATTENUATION_0DB
} |
| | Attenuation options for GPIO-triggered haptic effects. More...
|
| enum | cs40l5x_bank { CS40L5X_ROM_BANK
, CS40L5X_CUSTOM_BANK
, CS40L5X_BUZ_BANK
, CS40L5X_NO_BANK
} |
| | Wavetable sources for haptic effects. More...
|
| enum | cs40l5x_custom_index { CS40L5X_CUSTOM_0
, CS40L5X_CUSTOM_1
, CS40L5X_NUM_CUSTOM_EFFECTS
} |
| | Custom haptics source indices (0 or 1). More...
|
| enum | cs40l5x_error_type {
CS40L5X_ERROR_AMPLIFIER_SHORT = BIT(0)
, CS40L5X_ERROR_OVERTEMPERATURE = BIT(1)
, CS40L5X_ERROR_UNDERVOLTAGE = BIT(2)
, CS40L5X_ERROR_INDUCTOR_SHORT = BIT(3)
,
CS40L5X_ERROR_OVERCURRENT = BIT(4)
, CS40L5X_ERROR_BATTERY_UNDERVOLTAGE = BIT(4)
} |
| | Types of fatal CS40L5x hardware errors. More...
|
| enum | cs40l5x_logger { CS40L5X_LOGGER_DISABLE
, CS40L5X_LOGGER_ENABLE
, CS40L5X_LOGGER_NO_CHANGE
} |
| | Options for runtime haptics logging. More...
|
| enum | cs40l5x_logger_source { CS40L5X_LOGGER_BEMF
, CS40L5X_LOGGER_VBST
, CS40L5X_LOGGER_VMON
} |
| | Options for runtime haptics logging sources. More...
|
| enum | cs40l5x_logger_source_type { CS40L5X_LOGGER_MIN
, CS40L5X_LOGGER_MAX
, CS40L5X_LOGGER_MEAN
} |
| | Type specification for runtime haptics logging sources. More...
|
| enum | cs40l5x_trigger_edge { CS40L5X_RISING_EDGE
, CS40L5X_FALLING_EDGE
} |
| | Options for edge-triggered haptics effects. More...
|
|
| int | cs40l5x_calibrate (const struct device *const dev) |
| | Run calibration to derive ReDC and F0 values and apply results for click compensation.
|
| int | cs40l5x_configure_buzz (const struct device *const dev, const uint32_t frequency, const uint8_t level, const uint32_t duration) |
| | Configure ROM buzz for haptic playback.
|
| int | cs40l5x_configure_trigger (const struct device *const dev, const struct gpio_dt_spec *const gpio, const enum cs40l5x_bank bank, const uint8_t index, const enum cs40l5x_attenuation attenuation, const enum cs40l5x_trigger_edge edge) |
| | Configure edge-triggered haptic effect.
|
| int | cs40l5x_logger (const struct device *const dev, enum cs40l5x_logger logger_state) |
| | Update runtime haptics logging and get current status.
|
| int | cs40l5x_logger_get (const struct device *const dev, enum cs40l5x_logger_source source, enum cs40l5x_logger_source_type type, uint32_t *const value) |
| | Get runtime haptics logging data for the specified logger source.
|
| void | cs40l5x_register_error_callback (const struct device *dev, void(*error_callback)(const struct device *const haptic_dev, const uint32_t errors)) |
| | Register an application callback to handle fatal hardware errors.
|
| int | cs40l5x_select_output (const struct device *const dev, const enum cs40l5x_bank bank, const uint8_t index) |
| | Select haptic effect triggered via haptics_start_output().
|
| int | cs40l5x_set_gain (const struct device *const dev, const uint8_t gain) |
| | Configure gain for haptic effects triggered via haptics_start_output().
|
| int | cs40l5x_upload_pcm (const struct device *const dev, const enum cs40l5x_custom_index index, const uint16_t redc, const uint16_t f0, const int8_t *const samples, const uint16_t num_samples) |
| | Upload PCM effect to the specified index.
|
| int | cs40l5x_upload_pwle (const struct device *const dev, const enum cs40l5x_custom_index index, const struct cs40l5x_pwle_section *const sections, const uint8_t num_sections) |
| | Upload PWLE effect to the specified index.
|