Tachometer

This module provides a set of functionalities for managing the Tachometer system, including initialization, RPM calculations, RPM averaging, and configuration management to ensure accurate representation of engine RPM.

Configuration Parameters

All API functions have the first argument as the module ID.

Configuration

Name

Description

Range

enable

Enables Tachometer functionality.

0 (disabled) or 1 (enabled)

rpm_range

The RPM range for the tachometer.

Minimum to Maximum RPM (e.g., 0 to 8000)

bar_count

The number of bars for RPM display.

1 to 16

rpm_thresholds

RPM thresholds for bar activation.

Array of thresholds (configurable values).

average_period

The number of data points used for calculating average RPM.

1 to 100

APIs

The Tachometer module provides the following APIs to initialize, process, and update the tachometer data:

API Functions

Function

Description

rs_am_tachometer_init

Initializes the tachometer system with default configuration values.

rs_am_tachometer_process

Processes the tachometer system by calculating the RPM and updating bar states.

Error Codes

Each API for the tachometer module returns success or failure codes. For detailed information on the error codes, please refer to the following section:

Tachometer Module Header Details

The header file for tachometer modules, rs_am_tachometer.h, defines the required structures and APIs for initialization and processing.

Warning

doxygenfile: Cannot find file “rs_am_tachometer.h