forked from M-Labs/artiq
1
0
Fork 0

grabber: only advance when DVAL

This commit is contained in:
Robert Jördens 2018-09-06 11:01:08 +02:00
parent bf36786d45
commit 4d73fb5bc9
1 changed files with 4 additions and 2 deletions

View File

@ -85,10 +85,12 @@ class Parser(Module, AutoCSR):
self.sync.cl += [
last_lval.eq(lval),
last_fval.eq(fval),
pix.x.eq(pix.x + 1),
If(dval,
pix.x.eq(pix.x + 1),
),
If(~lval,
pix.x.eq(0),
If(last_lval, last_x.eq(pix.x)),
pix.x.eq(0),
If(last_fval & last_lval,
pix.y.eq(pix.y + 1)
)