Allen Nelson
Member
Tom Jenkins said:There is no way to tie two or three inputs to a single counter and insure an accurate count, unless you can insure that only one input at a time will be tripped AND insure that the first input has dropped out before the second is tripped! Remember, counters count off-to-on transitions. If one input is already on when the second trips, the counter will not see a transition and will not increment the count.
Huh?
That's not quite accurate, Tom. That's why I posted the timing diagram to show what has to happen with the counter. The one-scan-pulse of X2' is delayed (but only when X1 and X2 are active simultaneously) by 2 scans, in order for there to be a low-to-high-to-low transition from X1'.
I've got the code for two gates to one counter - it's not hard to expand it to three. I want to see what Waidesworld comes up with before I post my code.