Bioscara
DALSA's DIY SCARA Robot Arm.
Loading...
Searching...
No Matches
Public Member Functions | Protected Attributes | List of all members
bioscara_joint_firmware::Lowpass Class Reference

Simple discrete IIR lowpass filter. More...

#include <filters.h>

Public Member Functions

 Lowpass (float gain=1, float sampleTime=0.1, float timeconstant=1.0)
 Constucts and initializes the Lowpass filter.
 
float updateState (float u)
 Update the filter state. Must be called with the constant period Ts.
 
void resetState (void)
 Resets the filter state x to 0.0.
 

Protected Attributes

float K
 Filter gain.
 
float Ts
 Filter sampling time.
 
float tau
 Filter timeconstant.
 
float x
 Filter state.
 

Detailed Description

Simple discrete IIR lowpass filter.

Constructor & Destructor Documentation

◆ Lowpass()

bioscara_joint_firmware::Lowpass::Lowpass ( float  gain = 1,
float  sampleTime = 0.1,
float  timeconstant = 1.0 
)
inline

Constucts and initializes the Lowpass filter.

Parameters
gain
sampleTime
timeconstant

Member Function Documentation

◆ resetState()

void bioscara_joint_firmware::Lowpass::resetState ( void  )
inline

Resets the filter state x to 0.0.

◆ updateState()

float bioscara_joint_firmware::Lowpass::updateState ( float  u)
inline

Update the filter state. Must be called with the constant period Ts.

Returns
The updated filter state

Member Data Documentation

◆ K

float bioscara_joint_firmware::Lowpass::K
protected

Filter gain.

◆ tau

float bioscara_joint_firmware::Lowpass::tau
protected

Filter timeconstant.

◆ Ts

float bioscara_joint_firmware::Lowpass::Ts
protected

Filter sampling time.

◆ x

float bioscara_joint_firmware::Lowpass::x
protected

Filter state.


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