实现了对SD卡的SPI方式下读写操作

源代码在线查看: test.smp_dump.txt

软件大小: 2068 K
上传用户: c_word
关键词: SPI SD卡 方式 读写操作
下载地址: 免注册下载 普通下载 VIP

相关代码

				
				State Machine - |test|spiMaster:inst|readWriteSPIWireData:u_readWriteSPIWireData|CurrState_rwSPISt
				Name CurrState_rwSPISt.00 CurrState_rwSPISt.10 CurrState_rwSPISt.01 CurrState_rwSPISt.11 
				CurrState_rwSPISt.11 0 0 0 0 
				CurrState_rwSPISt.01 0 0 1 1 
				CurrState_rwSPISt.10 0 1 0 1 
				CurrState_rwSPISt.00 1 0 0 1 
				
				State Machine - |test|spiMaster:inst|sendCmd:u_sendCmd|CurrState_sndCmdSt
				Name CurrState_sndCmdSt.10011 CurrState_sndCmdSt.00000 CurrState_sndCmdSt.10001 CurrState_sndCmdSt.10000 CurrState_sndCmdSt.01111 CurrState_sndCmdSt.01110 CurrState_sndCmdSt.01101 CurrState_sndCmdSt.01100 CurrState_sndCmdSt.01011 CurrState_sndCmdSt.01010 CurrState_sndCmdSt.01001 CurrState_sndCmdSt.01000 CurrState_sndCmdSt.00111 CurrState_sndCmdSt.00110 CurrState_sndCmdSt.00101 CurrState_sndCmdSt.00100 CurrState_sndCmdSt.00011 CurrState_sndCmdSt.00010 CurrState_sndCmdSt.00001 CurrState_sndCmdSt.10010 
				CurrState_sndCmdSt.10010 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 
				CurrState_sndCmdSt.00001 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 
				CurrState_sndCmdSt.00010 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 1 
				CurrState_sndCmdSt.00011 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 
				CurrState_sndCmdSt.00100 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 1 
				CurrState_sndCmdSt.00101 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 1 
				CurrState_sndCmdSt.00110 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 1 
				CurrState_sndCmdSt.00111 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 1 
				CurrState_sndCmdSt.01000 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 
				CurrState_sndCmdSt.01001 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 1 
				CurrState_sndCmdSt.01010 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 1 
				CurrState_sndCmdSt.01011 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_sndCmdSt.01100 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_sndCmdSt.01101 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_sndCmdSt.01110 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_sndCmdSt.01111 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_sndCmdSt.10000 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_sndCmdSt.10001 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_sndCmdSt.00000 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_sndCmdSt.10011 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				
				State Machine - |test|spiMaster:inst|readWriteSDBlock:u_readWriteSDBlock|CurrState_rwBlkSt
				Name CurrState_rwBlkSt.101111 CurrState_rwBlkSt.101110 CurrState_rwBlkSt.101101 CurrState_rwBlkSt.101100 CurrState_rwBlkSt.101011 CurrState_rwBlkSt.101010 CurrState_rwBlkSt.101001 CurrState_rwBlkSt.101000 CurrState_rwBlkSt.100111 CurrState_rwBlkSt.100110 CurrState_rwBlkSt.100101 CurrState_rwBlkSt.100100 CurrState_rwBlkSt.100011 CurrState_rwBlkSt.100010 CurrState_rwBlkSt.100001 CurrState_rwBlkSt.100000 CurrState_rwBlkSt.011111 CurrState_rwBlkSt.011110 CurrState_rwBlkSt.011101 CurrState_rwBlkSt.011100 CurrState_rwBlkSt.011011 CurrState_rwBlkSt.011010 CurrState_rwBlkSt.011001 CurrState_rwBlkSt.011000 CurrState_rwBlkSt.010111 CurrState_rwBlkSt.010110 CurrState_rwBlkSt.010101 CurrState_rwBlkSt.010100 CurrState_rwBlkSt.010011 CurrState_rwBlkSt.010010 CurrState_rwBlkSt.010001 CurrState_rwBlkSt.010000 CurrState_rwBlkSt.001111 CurrState_rwBlkSt.001110 CurrState_rwBlkSt.001101 CurrState_rwBlkSt.001100 CurrState_rwBlkSt.001011 CurrState_rwBlkSt.001010 CurrState_rwBlkSt.001001 CurrState_rwBlkSt.001000 CurrState_rwBlkSt.000111 CurrState_rwBlkSt.000110 CurrState_rwBlkSt.000101 CurrState_rwBlkSt.000100 CurrState_rwBlkSt.000011 CurrState_rwBlkSt.000010 CurrState_rwBlkSt.000001 CurrState_rwBlkSt.000000 
				CurrState_rwBlkSt.000000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 
				CurrState_rwBlkSt.000001 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 
				CurrState_rwBlkSt.000010 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 1 
				CurrState_rwBlkSt.000011 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 
				CurrState_rwBlkSt.000100 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 1 
				CurrState_rwBlkSt.000101 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 1 
				CurrState_rwBlkSt.000110 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 1 
				CurrState_rwBlkSt.000111 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.001000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.001001 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.001010 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.001011 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.001100 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.001101 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.001110 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.001111 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.010000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.010001 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.010010 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.010011 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.010100 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.010101 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.010110 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.010111 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.011000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.011001 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.011010 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.011011 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.011100 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.011101 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.011110 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.011111 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.100000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.100001 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.100010 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.100011 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.100100 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.100101 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.100110 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.100111 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.101000 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.101001 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.101010 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.101011 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.101100 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.101101 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.101110 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_rwBlkSt.101111 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 
				
				State Machine - |test|spiMaster:inst|initSD:u_initSD|CurrState_initSDSt
				Name CurrState_initSDSt.1101 CurrState_initSDSt.1100 CurrState_initSDSt.1011 CurrState_initSDSt.1010 CurrState_initSDSt.1001 CurrState_initSDSt.1000 CurrState_initSDSt.0111 CurrState_initSDSt.0110 CurrState_initSDSt.0101 CurrState_initSDSt.0100 CurrState_initSDSt.0011 CurrState_initSDSt.0010 CurrState_initSDSt.0001 CurrState_initSDSt.0000 
				CurrState_initSDSt.0000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 
				CurrState_initSDSt.0001 0 0 0 0 0 0 0 0 0 0 0 0 1 1 
				CurrState_initSDSt.0010 0 0 0 0 0 0 0 0 0 0 0 1 0 1 
				CurrState_initSDSt.0011 0 0 0 0 0 0 0 0 0 0 1 0 0 1 
				CurrState_initSDSt.0100 0 0 0 0 0 0 0 0 0 1 0 0 0 1 
				CurrState_initSDSt.0101 0 0 0 0 0 0 0 0 1 0 0 0 0 1 
				CurrState_initSDSt.0110 0 0 0 0 0 0 0 1 0 0 0 0 0 1 
				CurrState_initSDSt.0111 0 0 0 0 0 0 1 0 0 0 0 0 0 1 
				CurrState_initSDSt.1000 0 0 0 0 0 1 0 0 0 0 0 0 0 1 
				CurrState_initSDSt.1001 0 0 0 0 1 0 0 0 0 0 0 0 0 1 
				CurrState_initSDSt.1010 0 0 0 1 0 0 0 0 0 0 0 0 0 1 
				CurrState_initSDSt.1011 0 0 1 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_initSDSt.1100 0 1 0 0 0 0 0 0 0 0 0 0 0 1 
				CurrState_initSDSt.1101 1 0 0 0 0 0 0 0 0 0 0 0 0 1 
				
				State Machine - |test|spiMaster:inst|spiCtrl:u_spiCtrl|CurrState_spiCtrlSt
				Name CurrState_spiCtrlSt.111 CurrState_spiCtrlSt.110 CurrState_spiCtrlSt.101 CurrState_spiCtrlSt.100 CurrState_spiCtrlSt.011 CurrState_spiCtrlSt.010 CurrState_spiCtrlSt.001 CurrState_spiCtrlSt.000 
				CurrState_spiCtrlSt.000 0 0 0 0 0 0 0 0 
				CurrState_spiCtrlSt.001 0 0 0 0 0 0 1 1 
				CurrState_spiCtrlSt.010 0 0 0 0 0 1 0 1 
				CurrState_spiCtrlSt.011 0 0 0 0 1 0 0 1 
				CurrState_spiCtrlSt.100 0 0 0 1 0 0 0 1 
				CurrState_spiCtrlSt.101 0 0 1 0 0 0 0 1 
				CurrState_spiCtrlSt.110 0 1 0 0 0 0 0 1 
				CurrState_spiCtrlSt.111 1 0 0 0 0 0 0 1 
							

相关资源