2-dimensional arrays
I would like to use the C programming language to create a two-dimensional array representing the following table:
A better diagram is provided in the attached file.
| idle | ready | transfer
-----------------------
CMD7(addr) | ready | transfer | idle
CMD7(not addr) | transfer | idle | ready
CMD9 | idle | transfer | ready
: : : :
etc. etc. etc. etc.
I have wrote some of the program and I am stuck now. I hope someone can kindly provide some help. Many grateful thanks in advance.
typedef enum
{
IDLE_STATE,
READY_STATE,
IDENTIFICATION_STATE,
STANDBY_STATE,
TRANSFER_STATE,
SENDING_DATA_STATE,
RECEIVE_DATA_STATE,
PROGRAMMING_STATE,
DISCONNECT_STATE,
INACTIVE_STATE,
WAIT_IRQ_STATE
} MMC_CurrentState;
int MMC_StateTransitionTable[][];

