Skip to content

Hi, i found a bug in your code #3

@calderonf

Description

@calderonf

please change the lines from FIR-filter-Arduino-Library/src/FIR.cpp lines 40 and 41 from

for (int i=0; i<FILTERTAPS; i++) {					// we step through the array
out += coef[i] * values[(i + k) % FILTERTAPS];	// ... and add and multiply each value to accumulate the output

to

for (int i=1; i<=FILTERTAPS; i++) {					// we step through the array
out += coef[i-1] * values[(i + k) % FILTERTAPS];	// ... and add and multiply each value to accumulate the output

you can easily check that your code doesn't work by checking an impulse response.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions