what is the difference between a state diagram and a flowchart?
A flowchart shows the processes that change the state of an object. A state diagram shows the actual changes in state, not the processes or commands that created those change.