This is the latest (main) BeagleBoard documentation. If you are looking for stable releases, use the drop-down menu on the bottom-left and select the desired version.

Function rc_filter_first_order_highpass

Function Documentation

int rc_filter_first_order_highpass(rc_filter_t *f, double dt, double tc)

Creates a first order high pass filter.

Any existing memory allocated for f is freed safely to avoid memory leaks and new memory is allocated for the new filter. dt is in units of seconds and time_constant is the number of seconds it takes to decay by 63.4% of a steady-state input. This can be used alongside rc_first_order_highpass to make a complementary filter pair.

Parameters
  • f[out] Pointer to user’s rc_filter_t struct

  • dt[in] desired timestep of discrete filter in seconds

  • tc[in] time constant: Seconds it takes to decay by 63.4% of a steady-state input

Returns

Returns 0 on success or -1 on failure.