Design Method - BJACK
Developing a bubble diagram is the first step in describing a state machine. The BJACK state diagram indicates the state transitions and the conditions that cause those transitions. There is a one-to-one correlation between the bubble diagram and the state diagram described in the source file. The following table describes the state identifiers (state machine states) illustrated in the bubble diagram and listed in the source file:
| State Identifier
|
Description |
| Clear
| Clear the state machine, adder, and displays.
|
| ShowHit
| Indicate that another card is needed. Light the HIT indicator.
|
| AddCard
| Add the adder input to the current count.
|
| Add10
| Add 10 to the current count, giving an ace a value of 11.
|
| Wait
| Wait until a card is taken from the reader.
|
| Test17
| Test the current count for a value less than 17.
|
| Test22
| Test the current count for a value less than 22.
|
| Sub10
| Add -10 to the count, restoring an ace to 1.
|
| ShowBust
| Indicate no more cards are needed. Light the BUST indicator.
|
| ShowStand
| Indicate no more cards are needed. Hit and BUST are not lit.
|