Tempo Tapper  1.0.0
A simple library to implement a tempo tapper
Public Attributes | List of all members
tempo_tapper Struct Reference

Tempo tapper struct. More...

#include <tempo_tapper.h>

Public Attributes

tt_time_t prd_sum
 Holds the sum of all measured/"tapped" periods.
 
tt_time_t lst_t
 Hold the clock time of the last tap.
 
int taps
 Number of taps. The inital val is -1, meaning the 1st tap does not count.
 

Detailed Description

Tempo tapper struct.

The following struct represents a virtual tempo tapper, and stores the necessary information to set, alter and receive a tempo value.

To create and interface with a tempo tapper struct, use the following functions:

To store time values, the platform varying tt_time_t typedef is used, as each platform offers its own preferred data type or struct to store time values (Ex. timeval on posix). This means that time arithmetic is implemented differently on every platform (see current_time(), add_time(), sub_time(), time_to_us(), reset_time()). For the library user, this is irrelevant as platform specific code is handled by the library internally. The only noticable external difference may be a variation in speed and precision.

Definition at line 87 of file tempo_tapper.h.


The documentation for this struct was generated from the following file: