1
\$\begingroup\$

Basically, I want to design a system where a vehicle goes through one of the sensors, then both, then leaves one, leaves both and finally counter goes up by 1. I've been able to draw the graph below.

graph of a carparkFSM

I am, however, having difficulty putting it in my states table. How would I go about it?

\$\endgroup\$

1 Answer 1

1
\$\begingroup\$

The two sensors detect direction from A to B and 1 event only after these 4 Grey counter cycles.

BA 00
01
11
10
00 =1

There must be sufficient hystereis to prevent false jitter on any transition. Otherwise false sequences are ignored and when 00 is reached the sequence must start over to trigger the output one shot or clock edge on a counter and not be trigger by transients on either sensor. (Unless you have other reasons to count going forward/reverse forward part way thru.)

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.