www.pudn.com > LPC17xx-spi-master.rar > main.c, change:2011-07-31,size:286b


#include "LPC17xx.h" 
 
uint8_t TAB[8]={0xa5,0x13,0xb0,0x56,0x92,0x80,0x88,0xc6}; 
 
int main() 
{ 
	uint8_t i;	 
	SystemInit (); 
	SPI_Init (); 
	while(1) 
	{ 
		for(i=0;i<8;i++) 
		{ 
			uint8_t data=TAB[i]; 
			SPI_CS_Low();  
			SPI_SendByte(data); 
			SPI_CS_High(); 
		}	 
	} 
}