Skip to content

Commit 4e0b737

Browse files
committed
fir.py: Fix bug identified in iss #2.
1 parent da5fb41 commit 4e0b737

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ it runs about three times faster (on the order of 15μs).
109109
The `fir_py` module uses a closure to enable the function to retain state
110110
between calls. Usage is as follows:
111111
```python
112-
from fir_py import fir_c
112+
from fir_py import create_fir
113113
from array import array
114114
# 21 tap LPF. Figures from TFilter.
115115
coeffs = array('i', (-1318, -3829, -4009, -717, 3359, 2177, -3706, -5613,

fir.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ def fir(r0, r1, r2):
7575
asr(r2, r7) # Scale result before summing
7676
add(r0, r2, r0)
7777
sub(r6, 1)
78-
bpl(FILT)
78+
bne(FILT) # > 0. bpl branched when >= 0
7979
pop({r3})
8080
mov(r8, r3) # Restore R8
8181

0 commit comments

Comments
 (0)