FSMs-Vol.4 Ch.11 5

Thread Starter

tshuck

Joined Oct 18, 2012
3,534
Hey guys, so, for the finite-state machine section, it describes the states for generating a FSM for creating a single pulse, lasting one clock cycle, for a push button input.

Nothing wrong with that, that's just fine, but the problem arises in the description of the states:
The third circle is the condition where our circuit waits for the button to be depressed before it returns to the "stand-by" condition.
this should say
The third circle is the condition where our circuit waits for the button to be released before it returns to the "stand-by" condition.
Also, a little further down:
There it waits until the button is depressed (Input goes 0) while transmitting a LOW on the output. Then it's all over again!
should be
There it waits until the button is released (Input goes 0) while transmitting a LOW on the output. Then it's all over again!
Unfortunately, pressed and depressed mean the exact same thing with respect to a push button, but I'm not blaming the author, English isn't his first language.;)


Edit:
Also, there is a spelling mistake on the next line, or so:
In the lower part of the circle is the output of our circuit. If we want our circuit to transmit a HIGH on a specific state, we put a 1 on that state. Ohterwise we put a 0.
should be
In the lower part of the circle is the output of our circuit. If we want our circuit to transmit a HIGH on a specific state, we put a 1 on that state, otherwise we put a 0.
The statements should be combined for proper grammar...
 
Last edited:

Georacer

Joined Nov 25, 2009
5,182
I 'm actually quite proud: So far no-one of the 3-4 reviewers has found a logic error on my guide. You are the first to point out some language and spelling errors, which are welcome and acknowledged.

Bill Marsden had made the same remark about the word depress. Maybe it was for another text of mine, but if was for this one, then it's not updated in a long time.

I was trying very hard not to make the sentences too long. I overdid it in that last part.
So, the spelling error you mention is actually the grammatical one, right?

What did you think of the tutorial, in all?
 

Thread Starter

tshuck

Joined Oct 18, 2012
3,534
I 'm actually quite proud: So far no-one of the 3-4 reviewers has found a logic error on my guide. You are the first to point out some language and spelling errors, which are welcome and acknowledged.

I was trying very hard not to make the sentences too long. I overdid it in that last part.
In that case, I have more...:(

This is more of a grammar/lost train of thought...
I will give the table of our example and use it to explain how will fill it in.
should be either
I will give the table of our example and use it to explain how to fill it in.
or
I will give the table of our example and use it to explain how we will fill it in.
take your pick.
 

Thread Starter

tshuck

Joined Oct 18, 2012
3,534
So, the spelling error you mention is actually the grammatical one, right?
Actually, it was both. "Otherwise" is spelled "Ohterwise" and the last part isn't a full sentence, so I wrote teh combined solution...

What did you think of the tutorial, in all?
Still working through it... There is a point I want to make, but I must finish before I do...:)
 

Thread Starter

tshuck

Joined Oct 18, 2012
3,534
I feel like I'm nit-picking:(
But I want Geo's work to be it's best, so....
For example, to go from 0 to 1, we need to feed J with 1 and we don't care wich input we feed to terminal K.
should say:
For example, to go from 0 to 1, we need to feed J with 1 and we don't care which input we feed to terminal K.
 

Thread Starter

tshuck

Joined Oct 18, 2012
3,534
What did you think of the tutorial, in all?
It is evident that you put a lot of effort into making this entry. Overall, I think it is good. I think it is a good introduction to state-machines.

That said, I think there are two places that you may want to address:
1.) Moore vs. Mealy State Machines

It is important to note that there are different type of state machines and their trade-offs.

2.) It isn't always advantageous to make state labels 00->01->10->11, it can greatly increase the speed/reliability of a system to make states different from the next 'numerically logical' number.

This isn't really a problem, so to speak, but it is useful in making a system less error-prone. It is, however, a fairly complex task and, probably, shouldn't be a topic for an introduction to FSMs:).

I have a problem with stating that the initial state is always 0. In making state transitions more reliable(and minimize input-forming logic), it may be the case that 0 isn't the best initial state. All state-machines will come up in a random state, the trick is getting the state to the initial state, the logic doesn't care if that initial is 10010101, or 0.

3.) State machine initialization sequencing. Figuring out what to do to initialize a state machine...
 

Georacer

Joined Nov 25, 2009
5,182
I feel like I'm nit-picking:(
But I want Geo's work to be it's best, so....

should say:
I realized relatively recently that which is written with an 'h' after the 'w', like all interrogative pronouns.

It is evident that you put a lot of effort into making this entry. Overall, I think it is good. I think it is a good introduction to state-machines.

That said, I think there are two places that you may want to address:
1.) Moore vs. Mealy State Machines

It is important to note that there are different type of state machines and their trade-offs.

2.) It isn't always advantageous to make state labels 00->01->10->11, it can greatly increase the speed/reliability of a system to make states different from the next 'numerically logical' number.

This isn't really a problem, so to speak, but it is useful in making a system less error-prone. It is, however, a fairly complex task and, probably, shouldn't be a topic for an introduction to FSMs:).

I have a problem with stating that the initial state is always 0. In making state transitions more reliable(and minimize input-forming logic), it may be the case that 0 isn't the best initial state. All state-machines will come up in a random state, the trick is getting the state to the initial state, the logic doesn't care if that initial is 10010101, or 0.

3.) State machine initialization sequencing. Figuring out what to do to initialize a state machine...
About 1): So far, I have not found a case where I needed the extra functionality of the Mealy machine badly. If you have a good example of the opposite, please show it. Thus, I chose to pick the most robust and easy to understand one, which is the Moore in my opinion. I didn't want to make the tutorial too complicated.

2) Again, it was about simplicity of the guide. Plus, I don't know any well described techniques to do this, other than "go with your gut".

A plus of calling the initial state 0, is that when you want to reset the machine, you can pull low the RESET pins of the FFs, which sounds right to the uninitiated. Pulling low a combination of RESET and SET pins would require a bit more explaining.

3) What kind of initialization? Care to elaborate?

Depending of where this conversation goes, we might add some final notes on the end of the chapter, or write another, "Advanced Course".

Thanks for your time!
 

Thread Starter

tshuck

Joined Oct 18, 2012
3,534
[...]like all interrogative pronouns.
...news to me:p

About 1): So far, I have not found a case where I needed the extra functionality of the Mealy machine badly. If you have a good example of the opposite, please show it. Thus, I chose to pick the most robust and easy to understand one, which is the Moore in my opinion. I didn't want to make the tutorial too complicated.
I agree with making it easy for beginners, in fact, I think you have the approach I would have taken and even took it a bit farther. I feel like there should be more sections on FSMs.

I think that, while Moore is easier to understand, it is important to understand that there are other ways of doing it, sometimes more efficient ways. A Moore machine, typically, has more hardware than a Mealy machine. I don't mean to say your entry should be modified, I mean to say that we should add more entries to take the concept further.

Here is a rather nice comparison of the two machines:
Mealy vs. Moore
and an overall comparison:
Overview: Mealy vs. Moore


2) Again, it was about simplicity of the guide. Plus, I don't know any well described techniques to do this, other than "go with your gut".

A plus of calling the initial state 0, is that when you want to reset the machine, you can pull low the RESET pins of the FFs, which sounds right to the uninitiated. Pulling low a combination of RESET and SET pins would require a bit more explaining.
I agree. I'm simply wary of the absolute description that initial is always 0.

3) What kind of initialization? Care to elaborate?
Hmmm.. I had written more, I guess it was accidentally deleted...:p

Since a state machine can come up in any state, it may be necessary to get the state machine into the initial state, but it isn't that important if implemented in a FPGA, or similar, as the synthesizer takes care of this...

Here are some good references:
Powerpoint on Initialization
FSM Optimizations
Good overall on FSMs(beginning at page 13, section 10.4, discusses the tradeoffs of Mealy vs. Moore for the same example you gave in your entry, a very good read!)

Depending of where this conversation goes, we might add some final notes on the end of the chapter, or write another, "Advanced Course".
I think your current one is good, I think "Advanced Course" is the way to go.
 

Georacer

Joined Nov 25, 2009
5,182
Okay, that odd "always" will leave too.

As of now, I don't have the material or the motivation to write a new article. The first one was my reply to a large number of students asking about FSMs on AAC during exams period.

But, I can see myself solving a nice puzzle, employing all the aforementioned advanced techniques if you can provide it.
 

Georacer

Joined Nov 25, 2009
5,182
Let me add your correction about always here, so that it's easy to find by the editor:

Next, we replace the words that describe the different states of the diagram with binary numbers. We start the enumeration from 0 which is assigned always on the initial state.
Remove the word alwyas.
 
Thread starter Similar threads Forum Replies Date
T Feedback and Suggestions 27
Similar threads
Additional Section on FSMs
Top